diff options
author | Sverker Eriksson <[email protected]> | 2018-01-15 20:45:34 +0100 |
---|---|---|
committer | Sverker Eriksson <[email protected]> | 2018-01-15 20:45:34 +0100 |
commit | f359cffc2590848c9ea4ff366d550c1351569479 (patch) | |
tree | 1c81ee58a804de478a0e96eae3e9b8e72cb8a11c /lib/hipe | |
parent | fd30cdac0f62c70336330d94ac944bb110932cc2 (diff) | |
parent | 0e448a62f46df4dad55c3bc724448e80a4d0048c (diff) | |
download | otp-f359cffc2590848c9ea4ff366d550c1351569479.tar.gz otp-f359cffc2590848c9ea4ff366d550c1351569479.tar.bz2 otp-f359cffc2590848c9ea4ff366d550c1351569479.zip |
Merge branch 'maint'
Diffstat (limited to 'lib/hipe')
-rw-r--r-- | lib/hipe/test/bs_SUITE_data/bs_construct.erl | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/lib/hipe/test/bs_SUITE_data/bs_construct.erl b/lib/hipe/test/bs_SUITE_data/bs_construct.erl index b9e7d93570..aa85626857 100644 --- a/lib/hipe/test/bs_SUITE_data/bs_construct.erl +++ b/lib/hipe/test/bs_SUITE_data/bs_construct.erl @@ -279,13 +279,22 @@ bad_floats() -> %% (incorrectly) signed. huge_binaries() -> - AlmostIllegal = id(<<0:(id((1 bsl 32)-8))>>), case erlang:system_info(wordsize) of - 4 -> huge_binaries_32(AlmostIllegal); + 4 -> + Old = erts_debug:set_internal_state(available_internal_state, true), + case erts_debug:set_internal_state(binary, (1 bsl 29)-1) of + false -> + io:format("\nNot enough memory to create 512Mb binary\n",[]); + Bin-> + huge_binaries_32(Bin) + end, + erts_debug:set_internal_state(available_internal_state, Old); + 8 -> ok end, garbage_collect(), id(<<0:(id((1 bsl 31)-1))>>), + garbage_collect(), id(<<0:(id((1 bsl 30)-1))>>), garbage_collect(), ok. |