nouveau: avoid LTO ODR warning (v2)
authorDave Airlie <airlied@redhat.com>
Mon, 13 Jul 2020 00:53:19 +0000 (10:53 +1000)
committerDave Airlie <airlied@redhat.com>
Mon, 13 Jul 2020 02:17:21 +0000 (12:17 +1000)
commit59b4c623c93c506a8ea3de39f7d3b51ccc52bef1
tree201a9d3ac1b68143be9b7a3b0c30a2f5e3ae6b2b
parentac002b15d3a77b9b16ce068e7ed9c314808eab82
nouveau: avoid LTO ODR warning (v2)

../src/gallium/drivers/nouveau/codegen/nv50_ir_target_nv50.cpp:69:8: warning: type ‘struct opProperties’ violates the C++ One Definition Rule [-Wodr]
   69 | struct opProperties
      |        ^
../src/gallium/drivers/nouveau/codegen/nv50_ir_target_nvc0.cpp:88:8: note: a different type is defined in another translation unit
   88 | struct opProperties
      |        ^
../src/gallium/drivers/nouveau/codegen/nv50_ir_target_nv50.cpp:77:17: note: the first difference of corresponding definitions is field ‘fShared’
   77 |    unsigned int fShared : 3;
      |                 ^
../src/gallium/drivers/nouveau/codegen/nv50_ir_target_nvc0.cpp:96:17: note: a field with different name is defined in another translation unit
   96 |    unsigned int fImmd  : 4; // last bit indicates if full immediate is suppoted

nvc0 code also has the same thing.

v2: rename both paths (Karol)

Reviewed-by: Karol Herbst <kherbst@redhat.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/5873>
src/gallium/drivers/nouveau/codegen/nv50_ir_target_nv50.cpp
src/gallium/drivers/nouveau/codegen/nv50_ir_target_nvc0.cpp
src/gallium/drivers/nouveau/codegen/nv50_ir_target_nvc0.h