[Mesa-dev] [PATCH] radeon: Fix parallel builds
Maarten Lankhorst
maarten.lankhorst at canonical.com
Thu Oct 4 06:50:31 PDT 2012
The generated td files won't initially show up in the *.td depend, which
opens up a small race in which parallel build can fail.
Signed-off-by: Maarten Lankhorst <maarten.lankhorst at canonical.com>
---
diff --git a/src/gallium/drivers/radeon/Makefile b/src/gallium/drivers/radeon/Makefile
index 43f668a..983789c 100644
--- a/src/gallium/drivers/radeon/Makefile
+++ b/src/gallium/drivers/radeon/Makefile
@@ -22,6 +22,8 @@ HAVE_LLVM_INTRINSICS = $(shell grep IntrinsicsR600.td $(LLVM_INCLUDEDIR)/llvm/In
gen: $(GENERATED_SOURCES)
+TD_GENERATED := SIRegisterInfo.td R600Intrinsics.td R600RegisterInfo.td
+
SIRegisterInfo.td: SIGenRegisterInfo.pl
$(PERL) $^ > $@
@@ -38,37 +40,37 @@ endif
R600RegisterInfo.td: R600GenRegisterInfo.pl
$(PERL) $^ > $@
-AMDGPUGenRegisterInfo.inc: *.td
+AMDGPUGenRegisterInfo.inc: *.td $(TD_GENERATED)
$(call tablegen, -gen-register-info, AMDGPU.td, $@)
-AMDGPUGenInstrInfo.inc: *.td
+AMDGPUGenInstrInfo.inc: *.td $(TD_GENERATED)
$(call tablegen, -gen-instr-info, AMDGPU.td, $@)
-AMDGPUGenAsmWriter.inc: *.td
+AMDGPUGenAsmWriter.inc: *.td $(TD_GENERATED)
$(call tablegen, -gen-asm-writer, AMDGPU.td, $@)
-AMDGPUGenDAGISel.inc: *.td
+AMDGPUGenDAGISel.inc: *.td $(TD_GENERATED)
$(call tablegen, -gen-dag-isel, AMDGPU.td, $@)
-AMDGPUGenCallingConv.inc: *.td
+AMDGPUGenCallingConv.inc: *.td $(TD_GENERATED)
$(call tablegen, -gen-callingconv, AMDGPU.td, $@)
-AMDGPUGenSubtargetInfo.inc: *.td
+AMDGPUGenSubtargetInfo.inc: *.td $(TD_GENERATED)
$(call tablegen, -gen-subtarget, AMDGPU.td, $@)
-AMDGPUGenEDInfo.inc: *.td
+AMDGPUGenEDInfo.inc: *.td $(TD_GENERATED)
$(call tablegen, -gen-enhanced-disassembly-info, AMDGPU.td, $@)
-AMDGPUGenIntrinsics.inc: *.td
+AMDGPUGenIntrinsics.inc: *.td $(TD_GENERATED)
$(call tablegen, -gen-tgt-intrinsic, AMDGPU.td, $@)
-AMDGPUGenCodeEmitter.inc: *.td
+AMDGPUGenCodeEmitter.inc: *.td $(TD_GENERATED)
$(call tablegen, -gen-emitter, AMDGPU.td, $@)
-AMDGPUGenMCCodeEmitter.inc: *.td
+AMDGPUGenMCCodeEmitter.inc: *.td $(TD_GENERATED)
$(call tablegen, -mc-emitter -gen-emitter, AMDGPU.td, $@)
-AMDGPUGenDFAPacketizer.inc: *.td
+AMDGPUGenDFAPacketizer.inc: *.td $(TD_GENERATED)
$(call tablegen, -gen-dfa-packetizer, AMDGPU.td, $@)
LOADER_LIBS=$(shell llvm-config --libs bitreader asmparser)
More information about the mesa-dev
mailing list