aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam
diff options
context:
space:
mode:
authorSverker Eriksson <[email protected]>2011-05-25 11:25:31 +0200
committerSverker Eriksson <[email protected]>2011-10-26 18:22:56 +0200
commit37d25fa469a6a084737abf8f980c1e4bb34ca9d9 (patch)
tree2456c81ac2c03b63f83b116af52400627a2449f3 /erts/emulator/beam
parent01c734e6a60bb9579c00079f7d81d197b684c9e3 (diff)
downloadotp-37d25fa469a6a084737abf8f980c1e4bb34ca9d9.tar.gz
otp-37d25fa469a6a084737abf8f980c1e4bb34ca9d9.tar.bz2
otp-37d25fa469a6a084737abf8f980c1e4bb34ca9d9.zip
erts-hipe: Change THE_NON_VALUE for HiPE enabled debug emulator
This is a work-around as there are hipe BIFs that return untagged integers that may be intepreted as THE_NON_VALUE (24). Hipe bifs that return offsets as untagged integers: hipe_bs_put_utf8 hipe_bs_put_utf16be hipe_bs_put_utf16le Hipe bifs that return raw pointers: hipe_find_na_or_make_stub hipe_nonclosure_address
Diffstat (limited to 'erts/emulator/beam')
-rw-r--r--erts/emulator/beam/erl_term.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/erts/emulator/beam/erl_term.h b/erts/emulator/beam/erl_term.h
index 1d75fa313c..bc20b2d798 100644
--- a/erts/emulator/beam/erl_term.h
+++ b/erts/emulator/beam/erl_term.h
@@ -331,7 +331,13 @@ _ET_DECLARE_CHECKED(Uint,thing_subtag,Eterm)
* we now use a non-zero bit-pattern in debug mode.
*/
#if ET_DEBUG
-#define THE_NON_VALUE _make_header(0,_TAG_HEADER_FLOAT)
+# ifdef HIPE
+ /* A very large (or negative) value as work-around for ugly hipe-bifs
+ that return untagged integers (eg hipe_bs_put_utf8) */
+# define THE_NON_VALUE _make_header((Uint)~0,_TAG_HEADER_FLOAT)
+# else
+# define THE_NON_VALUE _make_header(0,_TAG_HEADER_FLOAT)
+# endif
#else
#define THE_NON_VALUE (0)
#endif