Angel Pons has uploaded this change for review. ( https://review.coreboot.org/c/libhwbase/+/43556 )
Change subject: Makefile: Add `-gnatw_R` to suppress spurious warning ......................................................................
Makefile: Add `-gnatw_R` to suppress spurious warning
Looks like there's a new warning option that complains when the order of component declarations, component clauses, and bit-level layout do not all agree. However, we also enable `warnings are errors`. Plus, we use mismatched component representation clauses on purpose in libgfxinit's epilepsy-inducing gfxtest program to have RGB ordering on hardware that works with BGR ordering. Hardware is cursed, so silence this warning.
Change-Id: I1565e3e834cd47b7f53fd2202b38fdf01a0b7619 Signed-off-by: Angel Pons th3fanbus@gmail.com --- M Makefile 1 file changed, 4 insertions(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/libhwbase refs/changes/56/43556/1
diff --git a/Makefile b/Makefile index 14a7d4f..f690ea4 100644 --- a/Makefile +++ b/Makefile @@ -67,6 +67,9 @@ # H Suppress warnings on hiding: # It's too annoying, you run out of ideas for identifiers fast. # +# _R Suppress warnings for out-of-order record representation clauses: +# We are modelling hardware here! +# # T Suppress warnings for tracking of deleted conditional code: # We use static options to select code paths at compile time. # @@ -84,7 +87,7 @@ # .Y Disable information messages for why package spec needs body: # Those messages are annoying. But don't forget to enable those, # if you need the information. -ADAFLAGS += -gnatwa.eeD.HHTU.U.W.Y +ADAFLAGS += -gnatwa.eeD.HH_RTU.U.W.Y # Disable style checks for now ADAFLAGS += -gnatyN
Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/libhwbase/+/43556 )
Change subject: Makefile: Add `-gnatw_R` to suppress spurious warning ......................................................................
Patch Set 1:
I fear this will need some compiler detection. Unless you can make GCC 9 swallow it (I guess the option is new).
Hello Nico Huber, Patrick Georgi, Martin Roth,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/libhwbase/+/43556
to look at the new patch set (#2).
Change subject: Makefile: Add `-gnatw_R` to suppress spurious warning ......................................................................
Makefile: Add `-gnatw_R` to suppress spurious warning
Looks like there's a new warning option that complains when the order of component declarations, component clauses, and bit-level layout do not all agree. However, we also enable `warnings are errors`. Plus, we use mismatched component representation clauses on purpose in libgfxinit's epilepsy-inducing gfxtest program to have RGB ordering on hardware that works with BGR ordering. Hardware is cursed, so silence this warning.
Change-Id: I1565e3e834cd47b7f53fd2202b38fdf01a0b7619 Signed-off-by: Angel Pons th3fanbus@gmail.com --- M Makefile 1 file changed, 6 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/libhwbase refs/changes/56/43556/2
Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/libhwbase/+/43556 )
Change subject: Makefile: Add `-gnatw_R` to suppress spurious warning ......................................................................
Patch Set 2:
(2 comments)
https://review.coreboot.org/c/libhwbase/+/43556/2/Makefile File Makefile:
https://review.coreboot.org/c/libhwbase/+/43556/2/Makefile@94 PS2, Line 94: GCC_MAJOR = $(shell echo __GNUC__ | $(CC) -E - 2>/dev/null | tail -1) Would prefer this above (between `CC = ` and `CFLAGS +=`) so we don't have to move it if it's ever needed somewhere else.
https://review.coreboot.org/c/libhwbase/+/43556/2/Makefile@95 PS2, Line 95: ADAFLAGS += $(if $(filter 10,$(GCC_MAJOR)),-gnatw_R) Please place directly below the other `+= -gnatwa` above.
Hello Nico Huber, Patrick Georgi, Martin Roth, Arthur Heymans,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/libhwbase/+/43556
to look at the new patch set (#3).
Change subject: Makefile: Add `-gnatw_R` to suppress spurious warning ......................................................................
Makefile: Add `-gnatw_R` to suppress spurious warning
Looks like there's a new warning option that complains when the order of component declarations, component clauses, and bit-level layout do not all agree. However, we also enable `warnings are errors`. Plus, we use mismatched component representation clauses on purpose in libgfxinit's epilepsy-inducing gfxtest program to have RGB ordering on hardware that works with BGR ordering. Hardware is cursed, so silence this warning.
Change-Id: I1565e3e834cd47b7f53fd2202b38fdf01a0b7619 Signed-off-by: Angel Pons th3fanbus@gmail.com --- M Makefile 1 file changed, 6 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/libhwbase refs/changes/56/43556/3
Angel Pons has posted comments on this change. ( https://review.coreboot.org/c/libhwbase/+/43556 )
Change subject: Makefile: Add `-gnatw_R` to suppress spurious warning ......................................................................
Patch Set 3:
(2 comments)
https://review.coreboot.org/c/libhwbase/+/43556/2/Makefile File Makefile:
https://review.coreboot.org/c/libhwbase/+/43556/2/Makefile@94 PS2, Line 94: GCC_MAJOR = $(shell echo __GNUC__ | $(CC) -E - 2>/dev/null | tail -1)
Would prefer this above (between `CC = ` and `CFLAGS +=`) so we don't have […]
Done
https://review.coreboot.org/c/libhwbase/+/43556/2/Makefile@95 PS2, Line 95: ADAFLAGS += $(if $(filter 10,$(GCC_MAJOR)),-gnatw_R)
Please place directly below the other `+= -gnatwa` above.
Done
Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/libhwbase/+/43556 )
Change subject: Makefile: Add `-gnatw_R` to suppress spurious warning ......................................................................
Patch Set 3:
(1 comment)
https://review.coreboot.org/c/libhwbase/+/43556/3/Makefile File Makefile:
https://review.coreboot.org/c/libhwbase/+/43556/3/Makefile@73 PS3, Line 73: # We are modelling hardware here! Thought I commented already here (maybe stuck on a different PC). It's not about hardware. We just want the order in Code to differ from the compiled order, that's our (software) problem.
IMO, the whole idea about warning about this is spurious. Maybe just
We reorder record fields on purpose.
Hello Nico Huber, Patrick Georgi, Martin Roth, Arthur Heymans,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/libhwbase/+/43556
to look at the new patch set (#4).
Change subject: Makefile: Add `-gnatw_R` to suppress spurious warning ......................................................................
Makefile: Add `-gnatw_R` to suppress spurious warning
Looks like there's a new warning option that complains when the order of component declarations, component clauses, and bit-level layout do not all agree. However, we also enable `warnings are errors`. Plus, we use mismatched component representation clauses on purpose in libgfxinit's epilepsy-inducing gfxtest program to have RGB ordering on hardware that works with BGR ordering. Hardware is cursed, so silence this warning.
Change-Id: I1565e3e834cd47b7f53fd2202b38fdf01a0b7619 Signed-off-by: Angel Pons th3fanbus@gmail.com --- M Makefile 1 file changed, 6 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/libhwbase refs/changes/56/43556/4
Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/libhwbase/+/43556 )
Change subject: Makefile: Add `-gnatw_R` to suppress spurious warning ......................................................................
Patch Set 4: Verified+1 Code-Review+2
(1 comment)
https://review.coreboot.org/c/libhwbase/+/43556/3/Makefile File Makefile:
https://review.coreboot.org/c/libhwbase/+/43556/3/Makefile@73 PS3, Line 73: # We are modelling hardware here!
Thought I commented already here (maybe stuck on a different PC). It's […]
Thanks for your patients :)
Angel Pons has posted comments on this change. ( https://review.coreboot.org/c/libhwbase/+/43556 )
Change subject: Makefile: Add `-gnatw_R` to suppress spurious warning ......................................................................
Patch Set 4:
(1 comment)
https://review.coreboot.org/c/libhwbase/+/43556/3/Makefile File Makefile:
https://review.coreboot.org/c/libhwbase/+/43556/3/Makefile@73 PS3, Line 73: # We are modelling hardware here!
Thought I commented already here (maybe stuck on a different PC). It's […]
Patients or patience? My mainboards aren't my patients, they are my VICTIMS! >:D
Nico Huber has submitted this change. ( https://review.coreboot.org/c/libhwbase/+/43556 )
Change subject: Makefile: Add `-gnatw_R` to suppress spurious warning ......................................................................
Makefile: Add `-gnatw_R` to suppress spurious warning
Looks like there's a new warning option that complains when the order of component declarations, component clauses, and bit-level layout do not all agree. However, we also enable `warnings are errors`. Plus, we use mismatched component representation clauses on purpose in libgfxinit's epilepsy-inducing gfxtest program to have RGB ordering on hardware that works with BGR ordering. Hardware is cursed, so silence this warning.
Change-Id: I1565e3e834cd47b7f53fd2202b38fdf01a0b7619 Signed-off-by: Angel Pons th3fanbus@gmail.com Reviewed-on: https://review.coreboot.org/c/libhwbase/+/43556 Tested-by: Nico Huber nico.h@gmx.de Reviewed-by: Nico Huber nico.h@gmx.de --- M Makefile 1 file changed, 6 insertions(+), 0 deletions(-)
Approvals: Nico Huber: Verified; Looks good to me, approved
diff --git a/Makefile b/Makefile index 01e2aae..fb4c43c 100644 --- a/Makefile +++ b/Makefile @@ -43,6 +43,8 @@ CC = $(CROSS_COMPILE)gcc GNATBIND = $(CROSS_COMPILE)gnatbind
+GCC_MAJOR = $(shell echo __GNUC__ | $(CC) -E - 2>/dev/null | tail -1) + CFLAGS += -Wuninitialized -Wall -Werror CFLAGS += -pipe -g CFLAGS += -Wstrict-aliasing -Wshadow @@ -67,6 +69,9 @@ # H Suppress warnings on hiding: # It's too annoying, you run out of ideas for identifiers fast. # +# _R Suppress warnings for out-of-order record representation clauses: +# We reorder fields on purpose. +# # T Suppress warnings for tracking of deleted conditional code: # We use static options to select code paths at compile time. # @@ -85,6 +90,7 @@ # Those messages are annoying. But don't forget to enable those, # if you need the information. ADAFLAGS += -gnatwa.eeD.HHTU.U.W.Y +ADAFLAGS += $(if $(filter 10,$(GCC_MAJOR)),-gnatw_R) # Disable style checks for now ADAFLAGS += -gnatyN