Last Comment Bug 686317 - format string/argument list mismatches in ARMAssembler.h
: format string/argument list mismatches in ARMAssembler.h
Status: RESOLVED FIXED
[build-warning]
:
Product: Core
Classification: Components
Component: JavaScript Engine (show other bugs)
: unspecified
: ARM Android
: -- normal (vote)
: mozilla9
Assigned To: Jonathan Kew (:jfkthame)
:
:
Mentors:
: 686308 (view as bug list)
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-09-12 08:54 PDT by Jonathan Kew (:jfkthame)
Modified: 2011-09-16 03:54 PDT (History)
2 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
patch, correct format-string mismatches in ARMAssembler.h (4.71 KB, patch)
2011-09-12 08:54 PDT, Jonathan Kew (:jfkthame)
cdleary: review+
Details | Diff | Splinter Review

Description Jonathan Kew (:jfkthame) 2011-09-12 08:54:58 PDT
Created attachment 559865 [details] [diff] [review]
patch, correct format-string mismatches in ARMAssembler.h

When building for Android, I'm seeing a number of warnings about mismatches between printf-style format strings and the supplied arguments:

/home/jonathan/mozdev/mc-android/js/src/assembler/assembler/ARMAssembler.h: In member function 'void JSC::ARMAssembler::mem_imm_off(bool, bool, int, bool, int, int, JSC::ARMWord, JSC::ARMAssembler::Condition)':
/home/jonathan/mozdev/mc-android/js/src/assembler/assembler/ARMAssembler.h:591: warning: format '%u' expects type 'unsigned int', but argument 9 has type 'const char*'
/home/jonathan/mozdev/mc-android/js/src/assembler/assembler/ARMAssembler.h:591: warning: too many arguments for format
/home/jonathan/mozdev/mc-android/js/src/assembler/assembler/ARMAssembler.h: In member function 'void JSC::ARMAssembler::mem_reg_off(bool, bool, int, bool, int, int, int, JSC::ARMAssembler::Condition)':
/home/jonathan/mozdev/mc-android/js/src/assembler/assembler/ARMAssembler.h:630: warning: too many arguments for format
/home/jonathan/mozdev/mc-android/js/src/assembler/assembler/ARMAssembler.h: In static member function 'static void JSC::ARMAssembler::repatchInt32(void*, int32_t)':
/home/jonathan/mozdev/mc-android/js/src/assembler/assembler/ARMAssembler.h:1056: warning: format '%p' expects type 'void*', but argument 4 has type 'int32_t'
/home/jonathan/mozdev/mc-android/js/src/assembler/assembler/ARMAssembler.h: In member function 'void JSC::ARMAssembler::fcpyd_r(int, int, JSC::ARMAssembler::Condition)':
/home/jonathan/mozdev/mc-android/js/src/assembler/assembler/ARMAssembler.h:1610: warning: too few arguments for format
/home/jonathan/mozdev/mc-android/js/src/assembler/assembler/ARMAssembler.h: In member function 'void JSC::ARMAssembler::fabsd_r(int, int, JSC::ARMAssembler::Condition)':
/home/jonathan/mozdev/mc-android/js/src/assembler/assembler/ARMAssembler.h:1653: warning: too few arguments for format

The attached patch is my guess at how these should be resolved, from inspection of the lines in question; however, I don't speak ARM assembler, so it would be good to have someone check that they make sense.
Comment 1 Jonathan Kew (:jfkthame) 2011-09-14 00:08:23 PDT
Pushed to mozilla-inbound:
https://hg.mozilla.org/integration/mozilla-inbound/rev/1e7cfb65f195
Comment 2 Matt Brubeck (:mbrubeck) 2011-09-14 06:56:27 PDT
https://hg.mozilla.org/mozilla-central/rev/1e7cfb65f195
Comment 3 Jacob Bramley [:jbramley] 2011-09-16 03:54:07 PDT
*** Bug 686308 has been marked as a duplicate of this bug. ***

Note You need to log in before you can comment on or make changes to this bug.