[PATCH] [mips] Add assembler support for the .cprestore directive.

Ed Maste emaste at freebsd.org
Thu Jan 29 08:22:31 PST 2015

Comment at: lib/Target/Mips/AsmParser/MipsAsmParser.cpp:1386-1387
@@ +1385,4 @@
+    } else {
+      Warning(IDLoc, "no .cprestore used in PIC mode");
+    }
+  }
tomatabacu wrote:
> tomatabacu wrote:
> > emaste wrote:
> > > According to http://techpubs.sgi.com/library/dynaweb_docs/0530/SGI_Developer/books/Cplr_PTG/sgi_html/apa.html .cprestore should be a silent nop in non-PIC mode so that the same assembly source can be used in both PIC and non-PIC mode.
> > I know what you mean, but I believe you've highlighted the wrong code.
> > The warning we were talking about on Bugzilla is for using .cprestore in non-PIC mode (MipsAsmParser.cpp at 3373-3374), but the warning you've highlighted here is for *not* using .cprestore *in* PIC mode.
> Forgot to mention that the warning highlighted here is also implemented in GAS.
You're right, of course. I just wanted to make sure the comment was in the review and grabbed the wrong warning.



More information about the llvm-commits mailing list