diff options
author | Rickard Green <[email protected]> | 2017-02-27 18:02:50 +0100 |
---|---|---|
committer | Rickard Green <[email protected]> | 2017-02-27 18:02:50 +0100 |
commit | fc77f400672d7e9af2c495b96bee1228497acc0e (patch) | |
tree | 17c4ae8cf1762ad725c5d3f7d18b7a0ed5325d86 /erts/preloaded/src | |
parent | 87d87c57841dc7a295b3e74f807198e34df4adb4 (diff) | |
parent | 0a144d1fc4bebefcc74b0cb63fe76809bc041789 (diff) | |
download | otp-fc77f400672d7e9af2c495b96bee1228497acc0e.tar.gz otp-fc77f400672d7e9af2c495b96bee1228497acc0e.tar.bz2 otp-fc77f400672d7e9af2c495b96bee1228497acc0e.zip |
Merge branch 'rickard/prim_eval_receive' into maint
OTP-14241
* rickard/prim_eval_receive:
Ensure prim_eval:'receive' wont clobber def_arg_reg[0]
Diffstat (limited to 'erts/preloaded/src')
-rw-r--r-- | erts/preloaded/src/prim_eval.S | 41 |
1 files changed, 34 insertions, 7 deletions
diff --git a/erts/preloaded/src/prim_eval.S b/erts/preloaded/src/prim_eval.S index e7f09a870c..c6623f8e03 100644 --- a/erts/preloaded/src/prim_eval.S +++ b/erts/preloaded/src/prim_eval.S @@ -26,7 +26,7 @@ {attributes, []}. -{labels, 10}. +{labels, 14}. {function, 'receive', 2, 2}. @@ -36,6 +36,9 @@ {allocate,2,2}. {move,{x,1},{y,0}}. {move,{x,0},{y,1}}. + %% Call arg_reg_alloc() in order to ensure + %% that def_arg_reg[0] isn't clobbered + {call,0,{f,7}}. {label,3}. {loop_rec,{f,5},{x,0}}. {move,{y,1},{x,1}}. @@ -53,19 +56,43 @@ {deallocate,2}. return. - -{function, module_info, 0, 8}. +{function, arg_reg_alloc, 0, 7}. {label,6}. - {func_info,{atom,prim_eval},{atom,module_info},0}. + {func_info,{atom,prim_eval},{atom,arg_reg_alloc},0}. {label,7}. + {allocate,0,0}. + {move,{integer,134217727},{x,0}}. + {call_ext,1,{extfunc,erlang,bump_reductions,1}}. + {move,{atom,true},{x,3}}. + {move,{atom,true},{x,4}}. + {move,{atom,true},{x,2}}. + {move,{atom,true},{x,5}}. + {move,{atom,true},{x,1}}. + {move,{atom,true},{x,6}}. + {move,{atom,true},{x,0}}. + {call_last,7,{f,9},0}. + + +{function, arg_reg_alloc, 7, 9}. + {label,8}. + {func_info,{atom,prim_eval},{atom,arg_reg_alloc},7}. + {label,9}. + {move,{atom,ok},{x,0}}. + return. + + +{function, module_info, 0, 11}. + {label,10}. + {func_info,{atom,prim_eval},{atom,module_info},0}. + {label,11}. {move,{atom,prim_eval},{x,0}}. {call_ext_only,1,{extfunc,erlang,get_module_info,1}}. -{function, module_info, 1, 10}. - {label,8}. +{function, module_info, 1, 13}. + {label,12}. {func_info,{atom,prim_eval},{atom,module_info},1}. - {label,9}. + {label,13}. {move,{x,0},{x,1}}. {move,{atom,prim_eval},{x,0}}. {call_ext_only,2,{extfunc,erlang,get_module_info,2}}. |