diff options
author | Sverker Eriksson <sverker@erlang.org> | 2017-11-03 16:17:53 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-11-03 16:17:53 +0100 |
commit | a8264b52677abba29505a8bb597e2aaf6d3258d9 (patch) | |
tree | 64d2ebb3981ad0ead8ee65a8990df09e3718b76c /lib/hipe/rtl | |
parent | 3f09864488e77655c9bcb5c70a9b4aead46b3a36 (diff) | |
parent | 5369e34a892bfd8ab5aa98df330e3bbf19497b71 (diff) | |
download | otp-a8264b52677abba29505a8bb597e2aaf6d3258d9.tar.gz otp-a8264b52677abba29505a8bb597e2aaf6d3258d9.tar.bz2 otp-a8264b52677abba29505a8bb597e2aaf6d3258d9.zip |
Merge PR-1607 from sverker/hipe_bin_utf32_bug OTP-14740
Fix hipe bug in binary <<X/utf32>> construction
Diffstat (limited to 'lib/hipe/rtl')
-rw-r--r-- | lib/hipe/rtl/hipe_rtl_binary_construct.erl | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/lib/hipe/rtl/hipe_rtl_binary_construct.erl b/lib/hipe/rtl/hipe_rtl_binary_construct.erl index 52ea5db382..bc215e3abe 100644 --- a/lib/hipe/rtl/hipe_rtl_binary_construct.erl +++ b/lib/hipe/rtl/hipe_rtl_binary_construct.erl @@ -195,8 +195,13 @@ gen_rtl(BsOP, Dst, Args, TrueLblName, FalseLblName, SystemLimitLblName, ConstTab bs_validate_unicode -> [_Arg] = Args, - [hipe_rtl:mk_call([], bs_validate_unicode, Args, - TrueLblName, FalseLblName, not_remote)]; + [IsUnicode] = create_regs(1), + RetLbl = hipe_rtl:mk_new_label(), + [hipe_rtl:mk_call([IsUnicode], is_unicode, Args, + hipe_rtl:label_name(RetLbl), [], not_remote), + RetLbl, + hipe_rtl:mk_branch(IsUnicode, ne, hipe_rtl:mk_imm(0), + TrueLblName, FalseLblName, 0.99)]; bs_final -> Zero = hipe_rtl:mk_imm(0), |