File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -6843,7 +6843,12 @@ void GraphColor::stackCallProlog()
68436843{
68446844 // mov (8) r126.0<1>:ud r0.0<8;8,1>:ud
68456845 // This sets up the header for oword block r/w used for caller/callee-save
6846- // ToDo: check if this move is actually necessary
6846+
6847+ // Kernel should've already setup r0 in r126.
6848+ // Useful data in r126 is expected to be preserved by all functions.
6849+ if (kernel.fg .getIsStackCallFunc ())
6850+ return ;
6851+
68476852 auto dstRgn = builder.Create_Dst_Opnd_From_Dcl (builder.kernel .fg .scratchRegDcl , 1 );
68486853 auto srcRgn = builder.Create_Src_Opnd_From_Dcl (builder.getBuiltinR0 (), builder.getRegionStride1 ());
68496854
@@ -7803,7 +7808,6 @@ void GlobalRA::addCalleeSavePseudoCode()
78037808 builder.instList .clear ();
78047809}
78057810
7806-
78077811//
78087812// Insert pseudo operation to store fp at entry and restore before return.
78097813// Dst of store will be a temp that will run through RA and get an allocation.
You can’t perform that action at this time.
0 commit comments