diff options
author | Lukas Larsson <lukas@erlang.org> | 2022-01-10 11:52:13 +0100 |
---|---|---|
committer | Lukas Larsson <lukas@erlang.org> | 2022-01-10 11:52:13 +0100 |
commit | 33959fa295fc09af1acaabf34363ac57b3672a5c (patch) | |
tree | 00a00997f54aadcdc2f5f4c0cf0a7cfae26ea76b /erts/emulator | |
parent | a18a7f4ec7d8e37f1011eb1fdecabcacc9ffa9e4 (diff) | |
parent | 63900d18f5d8d4a41a6c8b4eaa70ccf327ccdbaf (diff) | |
download | erlang-33959fa295fc09af1acaabf34363ac57b3672a5c.tar.gz |
Merge branch 'lukas/24/test-fixes' into maint
* lukas/24/test-fixes:
gh: Do not build deps for windows
erts: Fix disable of MSACC
Diffstat (limited to 'erts/emulator')
-rw-r--r-- | erts/emulator/beam/erl_msacc.c | 2 | ||||
-rw-r--r-- | erts/emulator/test/statistics_SUITE.erl | 11 |
2 files changed, 12 insertions, 1 deletions
diff --git a/erts/emulator/beam/erl_msacc.c b/erts/emulator/beam/erl_msacc.c index bfde10a479..bf9637dfd7 100644 --- a/erts/emulator/beam/erl_msacc.c +++ b/erts/emulator/beam/erl_msacc.c @@ -42,7 +42,7 @@ #include "erl_msacc.h" #include "erl_bif_table.h" -#if ERTS_ENABLE_MSACC +#ifdef ERTS_ENABLE_MSACC static Eterm erts_msacc_gather_stats(ErtsMsAcc *msacc, ErtsHeapFactory *factory); static void erts_msacc_reset(ErtsMsAcc *msacc); diff --git a/erts/emulator/test/statistics_SUITE.erl b/erts/emulator/test/statistics_SUITE.erl index 0682b097f5..501bd7eb88 100644 --- a/erts/emulator/test/statistics_SUITE.erl +++ b/erts/emulator/test/statistics_SUITE.erl @@ -23,6 +23,7 @@ %% Tests the statistics/1 bif. -export([all/0, suite/0, groups/0, + init_per_testcase/2, wall_clock_sanity/1, wall_clock_zero_diff/1, wall_clock_update/1, runtime_sanity/1, @@ -61,6 +62,16 @@ groups() -> [runtime_sanity, runtime_zero_diff, runtime_update, runtime_diff]}, {run_queue, [], [run_queue_one]}]. +init_per_testcase(msacc, Config) -> + try erlang:statistics(microstate_accounting) of + _ -> + Config + catch _:_ -> + {skip, "Microstate accouning not available"} + end; +init_per_testcase(_, Config) -> + Config. + wall_clock_sanity(Config) when is_list(Config) -> erlang:yield(), {WallClock, _} = statistics(wall_clock), |