From owner-svn-src-all@FreeBSD.ORG Wed Mar 10 17:45:16 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4682B1065676; Wed, 10 Mar 2010 17:45:16 +0000 (UTC) (envelope-from rdivacky@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 315198FC19; Wed, 10 Mar 2010 17:45:16 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o2AHjGkL011017; Wed, 10 Mar 2010 17:45:16 GMT (envelope-from rdivacky@svn.freebsd.org) Received: (from rdivacky@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o2AHjFck011007; Wed, 10 Mar 2010 17:45:15 GMT (envelope-from rdivacky@svn.freebsd.org) Message-Id: <201003101745.o2AHjFck011007@svn.freebsd.org> From: Roman Divacky Date: Wed, 10 Mar 2010 17:45:15 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-vendor@freebsd.org X-SVN-Group: vendor MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r204961 - in vendor/llvm/dist: bindings/ocaml docs docs/tutorial examples include/llvm include/llvm/ADT include/llvm/Analysis include/llvm/CodeGen include/llvm/MC include/llvm/Support i... X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Mar 2010 17:45:16 -0000 Author: rdivacky Date: Wed Mar 10 17:45:15 2010 New Revision: 204961 URL: http://svn.freebsd.org/changeset/base/204961 Log: Update LLVM to r98164. Added: vendor/llvm/dist/lib/Target/ARM/ARMTargetObjectFile.cpp vendor/llvm/dist/test/Analysis/ScalarEvolution/unreachable-code.ll vendor/llvm/dist/test/CodeGen/ARM/armv4.ll vendor/llvm/dist/test/CodeGen/PowerPC/2010-03-09-indirect-call.ll vendor/llvm/dist/test/CodeGen/Thumb2/2010-03-08-addi12-ccout.ll vendor/llvm/dist/test/CodeGen/X86/machine-cse.ll vendor/llvm/dist/test/CodeGen/X86/sibcall.ll vendor/llvm/dist/test/CodeGen/XCore/ladd_lsub_combine.ll vendor/llvm/dist/test/CodeGen/XCore/mul64.ll vendor/llvm/dist/test/MC/MachO/reloc-diff.s vendor/llvm/dist/test/MC/MachO/reloc-pcrel.s vendor/llvm/dist/test/MC/MachO/zerofill-4.s vendor/llvm/dist/test/MC/MachO/zerofill-sect-align.s vendor/llvm/dist/test/Transforms/InstCombine/memset_chk.ll vendor/llvm/dist/test/Transforms/InstCombine/strcpy_chk.ll vendor/llvm/dist/test/Transforms/LCSSA/unreachable-use.ll Deleted: vendor/llvm/dist/lib/CodeGen/AsmPrinter/DwarfLabel.cpp vendor/llvm/dist/lib/CodeGen/AsmPrinter/DwarfLabel.h vendor/llvm/dist/test/CodeGen/X86/2007-10-16-IllegalAsm.ll vendor/llvm/dist/test/CodeGen/X86/tailcall2.ll vendor/llvm/dist/test/Transforms/SimplifyLibCalls/memset_chk.ll vendor/llvm/dist/test/Transforms/SimplifyLibCalls/strcpy_chk.ll Modified: vendor/llvm/dist/bindings/ocaml/Makefile.ocaml vendor/llvm/dist/docs/CodeGenerator.html vendor/llvm/dist/docs/LangRef.html vendor/llvm/dist/docs/SourceLevelDebugging.html vendor/llvm/dist/docs/WritingAnLLVMPass.html vendor/llvm/dist/docs/tutorial/OCamlLangImpl3.html vendor/llvm/dist/docs/tutorial/OCamlLangImpl4.html vendor/llvm/dist/docs/tutorial/OCamlLangImpl5.html vendor/llvm/dist/docs/tutorial/OCamlLangImpl6.html vendor/llvm/dist/docs/tutorial/OCamlLangImpl7.html vendor/llvm/dist/examples/Makefile vendor/llvm/dist/include/llvm/ADT/APFloat.h vendor/llvm/dist/include/llvm/ADT/DenseMap.h vendor/llvm/dist/include/llvm/ADT/DenseSet.h vendor/llvm/dist/include/llvm/Analysis/DebugInfo.h vendor/llvm/dist/include/llvm/Analysis/InlineCost.h vendor/llvm/dist/include/llvm/Analysis/PostDominators.h vendor/llvm/dist/include/llvm/CodeGen/AsmPrinter.h vendor/llvm/dist/include/llvm/CodeGen/DwarfWriter.h vendor/llvm/dist/include/llvm/CodeGen/MachineModuleInfo.h vendor/llvm/dist/include/llvm/MC/MCAsmInfo.h vendor/llvm/dist/include/llvm/MC/MCContext.h vendor/llvm/dist/include/llvm/MC/MCExpr.h vendor/llvm/dist/include/llvm/MC/MCStreamer.h vendor/llvm/dist/include/llvm/Metadata.h vendor/llvm/dist/include/llvm/Support/Dwarf.h vendor/llvm/dist/include/llvm/Target/TargetLowering.h vendor/llvm/dist/include/llvm/Target/TargetLoweringObjectFile.h vendor/llvm/dist/include/llvm/Target/TargetRegisterInfo.h vendor/llvm/dist/include/llvm/Transforms/IPO/InlinerPass.h vendor/llvm/dist/lib/Analysis/DebugInfo.cpp vendor/llvm/dist/lib/Analysis/InlineCost.cpp vendor/llvm/dist/lib/Analysis/LoopInfo.cpp vendor/llvm/dist/lib/Analysis/ScalarEvolution.cpp vendor/llvm/dist/lib/Analysis/ScalarEvolutionExpander.cpp vendor/llvm/dist/lib/CodeGen/AsmPrinter/AsmPrinter.cpp vendor/llvm/dist/lib/CodeGen/AsmPrinter/CMakeLists.txt vendor/llvm/dist/lib/CodeGen/AsmPrinter/DIE.cpp vendor/llvm/dist/lib/CodeGen/AsmPrinter/DIE.h vendor/llvm/dist/lib/CodeGen/AsmPrinter/DwarfDebug.cpp vendor/llvm/dist/lib/CodeGen/AsmPrinter/DwarfDebug.h vendor/llvm/dist/lib/CodeGen/AsmPrinter/DwarfException.cpp vendor/llvm/dist/lib/CodeGen/AsmPrinter/DwarfPrinter.cpp vendor/llvm/dist/lib/CodeGen/AsmPrinter/DwarfPrinter.h vendor/llvm/dist/lib/CodeGen/AsmPrinter/DwarfWriter.cpp vendor/llvm/dist/lib/CodeGen/BranchFolding.cpp vendor/llvm/dist/lib/CodeGen/LLVMTargetMachine.cpp vendor/llvm/dist/lib/CodeGen/LiveIntervalAnalysis.cpp vendor/llvm/dist/lib/CodeGen/MachineBasicBlock.cpp vendor/llvm/dist/lib/CodeGen/MachineCSE.cpp vendor/llvm/dist/lib/CodeGen/MachineFunction.cpp vendor/llvm/dist/lib/CodeGen/MachineInstr.cpp vendor/llvm/dist/lib/CodeGen/MachineModuleInfo.cpp vendor/llvm/dist/lib/CodeGen/PrologEpilogInserter.cpp vendor/llvm/dist/lib/CodeGen/PrologEpilogInserter.h vendor/llvm/dist/lib/CodeGen/SelectionDAG/SDDbgValue.h vendor/llvm/dist/lib/CodeGen/SelectionDAG/SelectionDAG.cpp vendor/llvm/dist/lib/CodeGen/SelectionDAG/SelectionDAGISel.cpp vendor/llvm/dist/lib/CodeGen/SimpleRegisterCoalescing.cpp vendor/llvm/dist/lib/CodeGen/TargetLoweringObjectFileImpl.cpp vendor/llvm/dist/lib/ExecutionEngine/JIT/JITDwarfEmitter.cpp vendor/llvm/dist/lib/MC/MCAsmInfo.cpp vendor/llvm/dist/lib/MC/MCAsmInfoDarwin.cpp vendor/llvm/dist/lib/MC/MCAssembler.cpp vendor/llvm/dist/lib/MC/MCContext.cpp vendor/llvm/dist/lib/MC/MCExpr.cpp vendor/llvm/dist/lib/MC/MCNullStreamer.cpp vendor/llvm/dist/lib/MC/MCParser/AsmParser.cpp vendor/llvm/dist/lib/MC/MCStreamer.cpp vendor/llvm/dist/lib/Support/APFloat.cpp vendor/llvm/dist/lib/Target/ARM/ARMBaseInstrInfo.h vendor/llvm/dist/lib/Target/ARM/ARMBaseRegisterInfo.cpp vendor/llvm/dist/lib/Target/ARM/ARMBaseRegisterInfo.h vendor/llvm/dist/lib/Target/ARM/ARMCodeEmitter.cpp vendor/llvm/dist/lib/Target/ARM/ARMISelLowering.cpp vendor/llvm/dist/lib/Target/ARM/ARMInstrInfo.td vendor/llvm/dist/lib/Target/ARM/ARMInstrNEON.td vendor/llvm/dist/lib/Target/ARM/ARMInstrThumb2.td vendor/llvm/dist/lib/Target/ARM/ARMInstrVFP.td vendor/llvm/dist/lib/Target/ARM/ARMMCAsmInfo.cpp vendor/llvm/dist/lib/Target/ARM/ARMSubtarget.cpp vendor/llvm/dist/lib/Target/ARM/ARMSubtarget.h vendor/llvm/dist/lib/Target/ARM/ARMTargetObjectFile.h vendor/llvm/dist/lib/Target/ARM/AsmPrinter/ARMAsmPrinter.cpp vendor/llvm/dist/lib/Target/ARM/AsmPrinter/ARMMCInstLower.cpp vendor/llvm/dist/lib/Target/ARM/CMakeLists.txt vendor/llvm/dist/lib/Target/ARM/Thumb1RegisterInfo.cpp vendor/llvm/dist/lib/Target/ARM/Thumb1RegisterInfo.h vendor/llvm/dist/lib/Target/ARM/Thumb2InstrInfo.cpp vendor/llvm/dist/lib/Target/Alpha/AlphaInstrInfo.td vendor/llvm/dist/lib/Target/Alpha/AlphaRegisterInfo.cpp vendor/llvm/dist/lib/Target/Alpha/AlphaRegisterInfo.h vendor/llvm/dist/lib/Target/Blackfin/BlackfinRegisterInfo.cpp vendor/llvm/dist/lib/Target/Blackfin/BlackfinRegisterInfo.h vendor/llvm/dist/lib/Target/CellSPU/CellSDKIntrinsics.td vendor/llvm/dist/lib/Target/CellSPU/SPUInstrInfo.td vendor/llvm/dist/lib/Target/CellSPU/SPUMathInstr.td vendor/llvm/dist/lib/Target/CellSPU/SPUNodes.td vendor/llvm/dist/lib/Target/CellSPU/SPURegisterInfo.cpp vendor/llvm/dist/lib/Target/CellSPU/SPURegisterInfo.h vendor/llvm/dist/lib/Target/MBlaze/MBlazeCallingConv.td vendor/llvm/dist/lib/Target/MBlaze/MBlazeISelDAGToDAG.cpp vendor/llvm/dist/lib/Target/MBlaze/MBlazeISelLowering.cpp vendor/llvm/dist/lib/Target/MBlaze/MBlazeISelLowering.h vendor/llvm/dist/lib/Target/MBlaze/MBlazeRegisterInfo.cpp vendor/llvm/dist/lib/Target/MBlaze/MBlazeRegisterInfo.h vendor/llvm/dist/lib/Target/MSP430/AsmPrinter/MSP430AsmPrinter.cpp vendor/llvm/dist/lib/Target/MSP430/AsmPrinter/MSP430InstPrinter.cpp vendor/llvm/dist/lib/Target/MSP430/AsmPrinter/MSP430MCInstLower.cpp vendor/llvm/dist/lib/Target/MSP430/MSP430RegisterInfo.cpp vendor/llvm/dist/lib/Target/MSP430/MSP430RegisterInfo.h vendor/llvm/dist/lib/Target/Mips/MipsRegisterInfo.cpp vendor/llvm/dist/lib/Target/Mips/MipsRegisterInfo.h vendor/llvm/dist/lib/Target/PIC16/PIC16DebugInfo.cpp vendor/llvm/dist/lib/Target/PIC16/PIC16RegisterInfo.cpp vendor/llvm/dist/lib/Target/PIC16/PIC16RegisterInfo.h vendor/llvm/dist/lib/Target/PowerPC/AsmPrinter/PPCAsmPrinter.cpp vendor/llvm/dist/lib/Target/PowerPC/PPCISelLowering.cpp vendor/llvm/dist/lib/Target/PowerPC/PPCInstrAltivec.td vendor/llvm/dist/lib/Target/PowerPC/PPCRegisterInfo.cpp vendor/llvm/dist/lib/Target/PowerPC/PPCRegisterInfo.h vendor/llvm/dist/lib/Target/Sparc/SparcRegisterInfo.cpp vendor/llvm/dist/lib/Target/Sparc/SparcRegisterInfo.h vendor/llvm/dist/lib/Target/SystemZ/SystemZInstrInfo.td vendor/llvm/dist/lib/Target/SystemZ/SystemZOperands.td vendor/llvm/dist/lib/Target/SystemZ/SystemZRegisterInfo.cpp vendor/llvm/dist/lib/Target/SystemZ/SystemZRegisterInfo.h vendor/llvm/dist/lib/Target/TargetLoweringObjectFile.cpp vendor/llvm/dist/lib/Target/X86/AsmPrinter/X86AsmPrinter.cpp vendor/llvm/dist/lib/Target/X86/AsmPrinter/X86MCInstLower.cpp vendor/llvm/dist/lib/Target/X86/X86ISelLowering.cpp vendor/llvm/dist/lib/Target/X86/X86ISelLowering.h vendor/llvm/dist/lib/Target/X86/X86Instr64bit.td vendor/llvm/dist/lib/Target/X86/X86InstrInfo.cpp vendor/llvm/dist/lib/Target/X86/X86InstrInfo.td vendor/llvm/dist/lib/Target/X86/X86InstrMMX.td vendor/llvm/dist/lib/Target/X86/X86InstrSSE.td vendor/llvm/dist/lib/Target/X86/X86MCAsmInfo.cpp vendor/llvm/dist/lib/Target/X86/X86RegisterInfo.cpp vendor/llvm/dist/lib/Target/X86/X86RegisterInfo.h vendor/llvm/dist/lib/Target/X86/X86TargetObjectFile.cpp vendor/llvm/dist/lib/Target/XCore/XCoreISelDAGToDAG.cpp vendor/llvm/dist/lib/Target/XCore/XCoreISelLowering.cpp vendor/llvm/dist/lib/Target/XCore/XCoreISelLowering.h vendor/llvm/dist/lib/Target/XCore/XCoreRegisterInfo.cpp vendor/llvm/dist/lib/Target/XCore/XCoreRegisterInfo.h vendor/llvm/dist/lib/Transforms/IPO/InlineAlways.cpp vendor/llvm/dist/lib/Transforms/IPO/InlineSimple.cpp vendor/llvm/dist/lib/Transforms/IPO/Inliner.cpp vendor/llvm/dist/lib/Transforms/InstCombine/InstCombine.h vendor/llvm/dist/lib/Transforms/InstCombine/InstCombineCalls.cpp vendor/llvm/dist/lib/Transforms/Scalar/SimplifyLibCalls.cpp vendor/llvm/dist/lib/Transforms/Utils/CloneFunction.cpp vendor/llvm/dist/lib/Transforms/Utils/LoopSimplify.cpp vendor/llvm/dist/lib/VMCore/Metadata.cpp vendor/llvm/dist/lib/VMCore/Verifier.cpp vendor/llvm/dist/runtime/Makefile vendor/llvm/dist/test/CodeGen/ARM/indirectbr.ll vendor/llvm/dist/test/CodeGen/MBlaze/cc.ll vendor/llvm/dist/test/CodeGen/MSP430/AddrMode-bis-rx.ll vendor/llvm/dist/test/CodeGen/MSP430/AddrMode-bis-xr.ll vendor/llvm/dist/test/CodeGen/MSP430/AddrMode-mov-rx.ll vendor/llvm/dist/test/CodeGen/MSP430/AddrMode-mov-xr.ll vendor/llvm/dist/test/CodeGen/PowerPC/indirectbr.ll vendor/llvm/dist/test/CodeGen/Thumb/2009-08-20-ISelBug.ll vendor/llvm/dist/test/CodeGen/Thumb2/machine-licm.ll vendor/llvm/dist/test/CodeGen/X86/2009-08-06-inlineasm.ll vendor/llvm/dist/test/CodeGen/X86/aliases.ll vendor/llvm/dist/test/CodeGen/X86/pre-split6.ll vendor/llvm/dist/test/CodeGen/X86/stack-color-with-reg.ll vendor/llvm/dist/test/CodeGen/XCore/addsub64.ll vendor/llvm/dist/test/FrontendC++/2010-02-17-DbgArtificialArg.cpp vendor/llvm/dist/test/MC/AsmParser/X86/x86_32-new-encoder.s vendor/llvm/dist/test/MC/Disassembler/simple-tests.txt vendor/llvm/dist/test/Transforms/InstCombine/objsize.ll vendor/llvm/dist/test/lit.cfg vendor/llvm/dist/tools/Makefile vendor/llvm/dist/unittests/Makefile.unittest vendor/llvm/dist/utils/TableGen/CodeGenDAGPatterns.cpp vendor/llvm/dist/utils/TableGen/DAGISelMatcher.cpp vendor/llvm/dist/utils/TableGen/DAGISelMatcher.h vendor/llvm/dist/utils/TableGen/DAGISelMatcherGen.cpp vendor/llvm/dist/utils/TableGen/DAGISelMatcherOpt.cpp vendor/llvm/dist/utils/lit/lit/TestRunner.py vendor/llvm/dist/utils/lit/lit/TestingConfig.py vendor/llvm/dist/utils/unittest/UnitTestMain/Makefile vendor/llvm/dist/utils/unittest/googletest/Makefile Modified: vendor/llvm/dist/bindings/ocaml/Makefile.ocaml ============================================================================== --- vendor/llvm/dist/bindings/ocaml/Makefile.ocaml Wed Mar 10 17:27:09 2010 (r204960) +++ vendor/llvm/dist/bindings/ocaml/Makefile.ocaml Wed Mar 10 17:45:15 2010 (r204961) @@ -66,35 +66,64 @@ Archive.CMA := $(strip $(OCAMLC) -a -cu Compile.CMX := $(strip $(OCAMLOPT) -c $(OCAMLCFLAGS) $(OCAMLDEBUGFLAG) -o) Archive.CMXA := $(strip $(OCAMLOPT) -a $(OCAMLAFLAGS) $(OCAMLDEBUGFLAG) -o) +ifdef OCAMLOPT +Archive.EXE := $(strip $(OCAMLOPT) -cc $(CXX) $(OCAMLCFLAGS) $(UsedOcamLibs:%=%.cmxa) $(OCAMLDEBUGFLAG) -o) +else +Archive.EXE := $(strip $(OCAMLC) -cc $(CXX) $(OCAMLCFLAGS) $(OCAMLDEBUGFLAG:%=%.cma) -o) +endif + # Source files OcamlSources1 := $(sort $(wildcard $(PROJ_SRC_DIR)/*.ml)) -OcamlHeaders1 := $(OcamlSources1:.ml=.mli) +OcamlHeaders1 := $(sort $(wildcard $(PROJ_SRC_DIR)/*.mli)) -OcamlSources := $(OcamlSources1:$(PROJ_SRC_DIR)/%=$(ObjDir)/%) -OcamlHeaders := $(OcamlHeaders1:$(PROJ_SRC_DIR)/%=$(ObjDir)/%) +OcamlSources2 := $(filter-out $(ExcludeSources),$(OcamlSources1)) +OcamlHeaders2 := $(filter-out $(ExcludeHeaders),$(OcamlHeaders1)) + +OcamlSources := $(OcamlSources2:$(PROJ_SRC_DIR)/%=$(ObjDir)/%) +OcamlHeaders := $(OcamlHeaders2:$(PROJ_SRC_DIR)/%=$(ObjDir)/%) # Intermediate files -LibraryCMA := $(ObjDir)/$(LIBRARYNAME).cma -LibraryCMXA := $(ObjDir)/$(LIBRARYNAME).cmxa ObjectsCMI := $(OcamlSources:%.ml=%.cmi) ObjectsCMO := $(OcamlSources:%.ml=%.cmo) ObjectsCMX := $(OcamlSources:%.ml=%.cmx) +ifdef LIBRARYNAME +LibraryCMA := $(ObjDir)/$(LIBRARYNAME).cma +LibraryCMXA := $(ObjDir)/$(LIBRARYNAME).cmxa +endif + +ifdef TOOLNAME +ToolEXE := $(ObjDir)/$(TOOLNAME)$(EXEEXT) +endif + # Output files # The .cmo files are the only intermediates; all others are to be installed. -LibraryA := $(OcamlDir)/lib$(LIBRARYNAME).a -OutputCMA := $(LibraryCMA:$(ObjDir)/%.cma=$(OcamlDir)/%.cma) -OutputCMXA := $(LibraryCMXA:$(ObjDir)/%.cmxa=$(OcamlDir)/%.cmxa) OutputsCMI := $(ObjectsCMI:$(ObjDir)/%.cmi=$(OcamlDir)/%.cmi) OutputsCMX := $(ObjectsCMX:$(ObjDir)/%.cmx=$(OcamlDir)/%.cmx) OutputLibs := $(UsedLibNames:%=$(OcamlDir)/%) +ifdef LIBRARYNAME +LibraryA := $(OcamlDir)/lib$(LIBRARYNAME).a +OutputCMA := $(LibraryCMA:$(ObjDir)/%.cma=$(OcamlDir)/%.cma) +OutputCMXA := $(LibraryCMXA:$(ObjDir)/%.cmxa=$(OcamlDir)/%.cmxa) +endif + +ifdef TOOLNAME +ifdef EXAMPLE_TOOL +OutputEXE := $(ExmplDir)/$(strip $(TOOLNAME))$(EXEEXT) +else +OutputEXE := $(ToolDir)/$(strip $(TOOLNAME))$(EXEEXT) +endif +endif + # Installation targets +DestLibs := $(UsedLibNames:%=$(PROJ_libocamldir)/%) + +ifdef LIBRARYNAME DestA := $(PROJ_libocamldir)/lib$(LIBRARYNAME).a DestCMA := $(PROJ_libocamldir)/$(LIBRARYNAME).cma DestCMXA := $(PROJ_libocamldir)/$(LIBRARYNAME).cmxa -DestLibs := $(UsedLibNames:%=$(PROJ_libocamldir)/%) - +endif ##===- Dependencies -------------------------------------------------------===## # Copy the sources into the intermediate directory because older ocamlc doesn't @@ -106,18 +135,27 @@ $(ObjDir)/%.mli: $(PROJ_SRC_DIR)/%.mli $ $(ObjDir)/%.ml: $(PROJ_SRC_DIR)/%.ml $(ObjDir)/.dir $(Verb) $(CP) -f $< $@ +$(ObjectsCMI): $(UsedOcamlInterfaces:%=$(OcamlDir)/%.cmi) + +ifdef LIBRARYNAME $(ObjDir)/$(LIBRARYNAME).ocamldep: $(OcamlSources) $(OcamlHeaders) \ $(OcamlDir)/.dir $(ObjDir)/.dir $(Verb) $(OCAMLDEP) $(OCAMLCFLAGS) $(OcamlSources) $(OcamlHeaders) > $@ -$(ObjectsCMI): $(UsedOcamlInterfaces:%=$(OcamlDir)/%.cmi) - -include $(ObjDir)/$(LIBRARYNAME).ocamldep +endif + +ifdef TOOLNAME +$(ObjDir)/$(TOOLNAME).ocamldep: $(OcamlSources) $(OcamlHeaders) \ + $(OcamlDir)/.dir $(ObjDir)/.dir + $(Verb) $(OCAMLDEP) $(OCAMLCFLAGS) $(OcamlSources) $(OcamlHeaders) > $@ +-include $(ObjDir)/$(TOOLNAME).ocamldep +endif ##===- Build static library from C sources --------------------------------===## -ifneq ($(ObjectsO),) +ifdef LibraryA all-local:: $(LibraryA) clean-local:: clean-a install-local:: install-a @@ -160,7 +198,7 @@ $(OcamlDir)/%.o: $(LibDir)/%.o $(Verb) ln -sf $< $@ clean-deplibs: - $(Verb) rm -f $(OutputLibs) + $(Verb) $(RM) -f $(OutputLibs) install-deplibs: $(Verb) $(MKDIR) $(PROJ_libocamldir) @@ -169,11 +207,12 @@ install-deplibs: done uninstall-deplibs: - $(Verb) rm -f $(DestLibs) + $(Verb) $(RM) -f $(DestLibs) ##===- Build ocaml interfaces (.mli's -> .cmi's) --------------------------===## +ifneq ($(OcamlHeaders),) all-local:: build-cmis clean-local:: clean-cmis install-local:: install-cmis @@ -212,10 +251,16 @@ uninstall-cmis:: $(EchoCmd) "Uninstalling $(PROJ_libocamldir)/$$i"; \ $(RM) -f "$(PROJ_libocamldir)/$$i"; \ done +endif ##===- Build ocaml bytecode archive (.ml's -> .cmo's -> .cma) -------------===## +$(ObjDir)/%.cmo: $(ObjDir)/%.ml + $(Echo) "Compiling $(notdir $<) for $(BuildMode) build" + $(Verb) $(Compile.CMO) $@ $< + +ifdef LIBRARYNAME all-local:: $(OutputCMA) clean-local:: clean-cma install-local:: install-cma @@ -228,10 +273,6 @@ $(LibraryCMA): $(ObjectsCMO) $(OcamlDir) $(Echo) "Archiving $(notdir $@) for $(BuildMode) build" $(Verb) $(Archive.CMA) $@ $(ObjectsCMO) -$(ObjDir)/%.cmo: $(ObjDir)/%.ml - $(Echo) "Compiling $(notdir $<) for $(BuildMode) build" - $(Verb) $(Compile.CMO) $@ $< - clean-cma:: $(Verb) $(RM) -f $(OutputCMA) $(UsedLibNames:%=$(OcamlDir)/%) @@ -243,7 +284,7 @@ install-cma:: $(OutputCMA) uninstall-cma:: $(Echo) "Uninstalling $(DestCMA)" -$(Verb) $(RM) -f $(DestCMA) - +endif ##===- Build optimized ocaml archive (.ml's -> .cmx's -> .cmxa, .a) -------===## @@ -251,6 +292,14 @@ uninstall-cma:: # If unavailable, 'configure' will not define OCAMLOPT in Makefile.config. ifdef OCAMLOPT +$(OcamlDir)/%.cmx: $(ObjDir)/%.cmx + $(Verb) $(CP) -f $< $@ + +$(ObjDir)/%.cmx: $(ObjDir)/%.ml + $(Echo) "Compiling optimized $(notdir $<) for $(BuildMode) build" + $(Verb) $(Compile.CMX) $@ $< + +ifdef LIBRARYNAME all-local:: $(OutputCMXA) $(OutputsCMX) clean-local:: clean-cmxa install-local:: install-cmxa @@ -260,18 +309,11 @@ $(OutputCMXA): $(LibraryCMXA) $(Verb) $(CP) -f $< $@ $(Verb) $(CP) -f $(<:.cmxa=.a) $(@:.cmxa=.a) -$(OcamlDir)/%.cmx: $(ObjDir)/%.cmx - $(Verb) $(CP) -f $< $@ - $(LibraryCMXA): $(ObjectsCMX) $(Echo) "Archiving $(notdir $@) for $(BuildMode) build" $(Verb) $(Archive.CMXA) $@ $(ObjectsCMX) $(Verb) $(RM) -f $(@:.cmxa=.o) -$(ObjDir)/%.cmx: $(ObjDir)/%.ml - $(Echo) "Compiling optimized $(notdir $<) for $(BuildMode) build" - $(Verb) $(Compile.CMX) $@ $< - clean-cmxa:: $(Verb) $(RM) -f $(OutputCMXA) $(OutputCMXA:.cmxa=.a) $(OutputsCMX) @@ -295,7 +337,27 @@ uninstall-cmxa:: $(EchoCmd) "Uninstalling $(PROJ_libocamldir)/$$i"; \ $(RM) -f $(PROJ_libocamldir)/$$i; \ done +endif +endif + +##===- Build executables --------------------------------------------------===## + +ifdef TOOLNAME +all-local:: $(OutputEXE) +clean-local:: clean-exe + +$(OutputEXE): $(ToolEXE) $(OcamlDir)/.dir + $(Verb) $(CP) -f $< $@ +ifndef OCAMLOPT +$(ToolEXE): $(ObjectsCMO) $(OcamlDir)/.dir + $(Echo) "Archiving $(notdir $@) for $(BuildMode) build" + $(Verb) $(Archive.EXE) $@ $< +else +$(ToolEXE): $(ObjectsCMX) $(OcamlDir)/.dir + $(Echo) "Archiving $(notdir $@) for $(BuildMode) build" + $(Verb) $(Archive.EXE) $@ $< +endif endif ##===- Generate documentation ---------------------------------------------===## @@ -325,7 +387,10 @@ printcamlvars:: $(Echo) "LibraryCMA : " '$(LibraryCMA)' $(Echo) "LibraryCMXA : " '$(LibraryCMXA)' $(Echo) "OcamlSources1: " '$(OcamlSources1)' + $(Echo) "OcamlSources2: " '$(OcamlSources2)' $(Echo) "OcamlSources : " '$(OcamlSources)' + $(Echo) "OcamlHeaders1: " '$(OcamlHeaders1)' + $(Echo) "OcamlHeaders2: " '$(OcamlHeaders2)' $(Echo) "OcamlHeaders : " '$(OcamlHeaders)' $(Echo) "ObjectsCMI : " '$(ObjectsCMI)' $(Echo) "ObjectsCMO : " '$(ObjectsCMO)' @@ -340,4 +405,6 @@ printcamlvars:: .PHONY: printcamlvars build-cmis \ clean-a clean-cmis clean-cma clean-cmxa \ install-a install-cmis install-cma install-cmxa \ - uninstall-a uninstall-cmis uninstall-cma uninstall-cmxa + install-exe \ + uninstall-a uninstall-cmis uninstall-cma uninstall-cmxa \ + uninstall-exe Modified: vendor/llvm/dist/docs/CodeGenerator.html ============================================================================== --- vendor/llvm/dist/docs/CodeGenerator.html Wed Mar 10 17:27:09 2010 (r204960) +++ vendor/llvm/dist/docs/CodeGenerator.html Wed Mar 10 17:45:15 2010 (r204961) @@ -86,6 +86,7 @@
  • Target-specific Implementation Notes
    • Tail call optimization
    • +
    • Sibling call optimization
    • The X86 backend
    • The PowerPC backend
        @@ -1734,6 +1735,50 @@ define fastcc i32 @tailcaller(i32 %in1, + +
        + +

        Sibling call optimization is a restricted form of tail call optimization. + Unlike tail call optimization described in the previous section, it can be + performed automatically on any tail calls when -tailcallopt option + is not specified.

        + +

        Sibling call optimization is currently performed on x86/x86-64 when the + following constraints are met:

        + +
          +
        • Caller and callee have the same calling convention. It can be either + c or fastcc. + +
        • The call is a tail call - in tail position (ret immediately follows call + and ret uses value of call or is void).
        • + +
        • Caller and callee have matching return type or the callee result is not + used. + +
        • If any of the callee arguments are being passed in stack, they must be + available in caller's own incoming argument stack and the frame offsets + must be the same. +
        + +

        Example:

        +
        +
        +declare i32 @bar(i32, i32)
        +
        +define i32 @foo(i32 %a, i32 %b, i32 %c) {
        +entry:
        +  %0 = tail call i32 @bar(i32 %a, i32 %b)
        +  ret i32 %0
        +}
        +
        +
        + +
        + + @@ -2116,7 +2161,7 @@ MOVSX32rm16 -> movsx, 32-bit register Chris Lattner
        The LLVM Compiler Infrastructure
        - Last modified: $Date: 2010-03-02 02:11:08 +0100 (Tue, 02 Mar 2010) $ + Last modified: $Date: 2010-03-08 22:05:02 +0100 (Mon, 08 Mar 2010) $ Modified: vendor/llvm/dist/docs/LangRef.html ============================================================================== --- vendor/llvm/dist/docs/LangRef.html Wed Mar 10 17:27:09 2010 (r204960) +++ vendor/llvm/dist/docs/LangRef.html Wed Mar 10 17:45:15 2010 (r204961) @@ -5149,8 +5149,11 @@ Loop: ; Infinite loop that counts a ret instruction. If the "tail" marker is present, the function call is eligible for tail call optimization, but might not in fact be - optimized into a jump. As of this writing, the extra requirements for - a call to actually be optimized are: + optimized into a jump. The code generator may optimize calls marked + "tail" with either 1) automatic + sibling call optimization when the caller and callee have + matching signatures, or 2) forced tail call optimization when the + following extra requirements are met:
        • Caller and callee both have the calling convention fastcc.
        • @@ -7470,7 +7473,7 @@ LLVM.

          Chris Lattner
          The LLVM Compiler Infrastructure
          - Last modified: $Date: 2010-03-05 00:44:48 +0100 (Fri, 05 Mar 2010) $ + Last modified: $Date: 2010-03-08 22:05:02 +0100 (Mon, 08 Mar 2010) $ Modified: vendor/llvm/dist/docs/SourceLevelDebugging.html ============================================================================== --- vendor/llvm/dist/docs/SourceLevelDebugging.html Wed Mar 10 17:27:09 2010 (r204960) +++ vendor/llvm/dist/docs/SourceLevelDebugging.html Wed Mar 10 17:45:15 2010 (r204961) @@ -25,6 +25,7 @@
        • Debug information descriptors
          • Compile unit descriptors
          • +
          • File descriptors
          • Global variable descriptors
          • Subprogram descriptors
          • Block descriptors
          • @@ -255,7 +256,7 @@ height="369">

            To provide basic functionality, the LLVM debugger does have to make some assumptions about the source-level language being debugged, though it keeps these to a minimum. The only common features that the LLVM debugger assumes - exist are source files, + exist are source files, and program objects. These abstract objects are used by a debugger to form stack traces, show information about local variables, etc.

            @@ -307,8 +308,8 @@ height="369"> of tags are loosely bound to the tag values of DWARF information entries. However, that does not restrict the use of the information supplied to DWARF targets. To facilitate versioning of debug information, the tag is augmented - with the current debug version (LLVMDebugVersion = 7 << 16 or 0x70000 or - 458752.)

            + with the current debug version (LLVMDebugVersion = 8 << 16 or 0x80000 or + 524288.)

            The details of the various descriptors follow.

            @@ -346,18 +347,36 @@ height="369"> that produced it.

            Compile unit descriptors provide the root context for objects declared in a - specific source file. Global variables and top level functions would be - defined using this context. Compile unit descriptors also provide context - for source line correspondence.

            - -

            Each input file is encoded as a separate compile unit in LLVM debugging - information output. However, many target specific tool chains prefer to - encode only one compile unit in an object file. In this situation, the LLVM - code generator will include debugging information entities in the compile - unit that is marked as main compile unit. The code generator accepts maximum - one main compile unit per module. If a module does not contain any main - compile unit then the code generator will emit multiple compile units in the - output object file.

            + specific compilation unit. File descriptors are defined using this context.

            + + + + + + +
            + +
            +
            +!0 = metadata !{
            +  i32,       ;; Tag = 41 + LLVMDebugVersion 
            +             ;; (DW_TAG_file_type)
            +  metadata,  ;; Source file name
            +  metadata,  ;; Source file directory (includes trailing slash)
            +  metadata   ;; Reference to compile unit where defined
            +}
            +
            +
            + +

            These descriptors contain informations for a file. Global variables and top + level functions would be defined using this context.k File descriptors also + provide context for source line correspondence.

            + +

            Each input file is encoded as a separate file descriptor in LLVM debugging + information output. Each file descriptor would be defined using a + compile unit.

            @@ -378,7 +397,7 @@ height="369"> metadata, ;; Name metadata, ;; Display name (fully qualified C++ name) metadata, ;; MIPS linkage name (for C++) - metadata, ;; Reference to compile unit where defined + metadata, ;; Reference to file where defined i32, ;; Line number where defined metadata, ;; Reference to type descriptor i1, ;; True if the global is local to compile unit (static) @@ -410,7 +429,7 @@ provide details such as name, type and w metadata, ;; Name metadata, ;; Display name (fully qualified C++ name) metadata, ;; MIPS linkage name (for C++) - metadata, ;; Reference to compile unit where defined + metadata, ;; Reference to file where defined i32, ;; Line number where defined metadata, ;; Reference to type descriptor i1, ;; True if the global is local to compile unit (static) @@ -461,7 +480,7 @@ provide details such as name, type and w ;; (DW_TAG_base_type) metadata, ;; Reference to context (typically a compile unit) metadata, ;; Name (may be "" for anonymous types) - metadata, ;; Reference to compile unit where defined (may be NULL) + metadata, ;; Reference to file where defined (may be NULL) i32, ;; Line number where defined (may be 0) i64, ;; Size in bits i64, ;; Alignment in bits @@ -512,7 +531,7 @@ DW_ATE_unsigned_char = 8 i32, ;; Tag (see below) metadata, ;; Reference to context metadata, ;; Name (may be "" for anonymous types) - metadata, ;; Reference to compile unit where defined (may be NULL) + metadata, ;; Reference to file where defined (may be NULL) i32, ;; Line number where defined (may be 0) i32, ;; Size in bits i32, ;; Alignment in bits @@ -580,7 +599,7 @@ DW_TAG_restrict_type = 55 i32, ;; Tag (see below) metadata, ;; Reference to context metadata, ;; Name (may be "" for anonymous types) - metadata, ;; Reference to compile unit where defined (may be NULL) + metadata, ;; Reference to file where defined (may be NULL) i32, ;; Line number where defined (may be 0) i64, ;; Size in bits i64, ;; Alignment in bits @@ -715,7 +734,7 @@ DW_TAG_inheritance = 28 i32, ;; Tag (see below) metadata, ;; Context metadata, ;; Name - metadata, ;; Reference to compile unit where defined + metadata, ;; Reference to file where defined i32, ;; Line number where defined metadata ;; Type descriptor } @@ -1012,10 +1031,10 @@ int main(int argc, char *argv[]) {
             ...
             ;;
            -;; Define the compile unit for the source file "/Users/mine/sources/MySource.cpp".
            +;; Define the compile unit for the main source file "/Users/mine/sources/MySource.cpp".
             ;;
            -!3 = metadata !{
            -  i32 458769,    ;; Tag
            +!2 = metadata !{
            +  i32 524305,    ;; Tag
               i32 0,         ;; Unused
               i32 4,         ;; Language Id
               metadata !"MySource.cpp", 
            @@ -1027,19 +1046,24 @@ int main(int argc, char *argv[]) {
               i32 0}         ;; Runtime version
             
             ;;
            -;; Define the compile unit for the header file "/Users/mine/sources/MyHeader.h".
            +;; Define the file for the file "/Users/mine/sources/MySource.cpp".
             ;;
             !1 = metadata !{
            -  i32 458769,    ;; Tag
            -  i32 0,         ;; Unused
            -  i32 4,         ;; Language Id
            -  metadata !"MyHeader.h", 
            +  i32 524329,    ;; Tag
            +  metadata !"MySource.cpp", 
               metadata !"/Users/mine/sources", 
            -  metadata !"4.2.1 (Based on Apple Inc. build 5649) (LLVM build 00)", 
            -  i1 false,      ;; Main Compile Unit
            -  i1 false,      ;; Optimized compile unit
            -  metadata !"",  ;; Compiler flags
            -  i32 0}         ;; Runtime version
            +  metadata !3    ;; Compile unit
            +}
            +
            +;;
            +;; Define the file for the file "/Users/mine/sources/Myheader.h"
            +;;
            +!3 = metadata !{
            +  i32 524329,    ;; Tag
            +  metadata !"Myheader.h"
            +  metadata !"/Users/mine/sources", 
            +  metadata !3    ;; Compile unit
            +}
             
             ...
             
            @@ -1081,15 +1105,15 @@ int MyGlobal = 100; ;; variable anchor and the global variable itself. ;; !0 = metadata !{ - i32 458804, ;; Tag + i32 524340, ;; Tag i32 0, ;; Unused metadata !1, ;; Context metadata !"MyGlobal", ;; Name metadata !"MyGlobal", ;; Display Name metadata !"MyGlobal", ;; Linkage Name - metadata !1, ;; Compile Unit + metadata !3, ;; Compile Unit i32 1, ;; Line Number - metadata !2, ;; Type + metadata !4, ;; Type i1 false, ;; Is a local variable i1 true, ;; Is this a definition i32* @MyGlobal ;; The global variable @@ -1099,11 +1123,11 @@ int MyGlobal = 100; ;; Define the basic type of 32 bit signed integer. Note that since int is an ;; intrinsic type the source file is NULL and line 0. ;; -!2 = metadata !{ - i32 458788, ;; Tag +!4 = metadata !{ + i32 524324, ;; Tag metadata !1, ;; Context metadata !"int", ;; Name - metadata !1, ;; Compile Unit + metadata !1, ;; File i32 0, ;; Line number i64 32, ;; Size in Bits i64 32, ;; Align in Bits @@ -1143,16 +1167,16 @@ int main(int argc, char *argv[]) { ;; anchor is 46, which is the same as the tag for subprograms ;; (46 = DW_TAG_subprogram.) ;; -!0 = metadata !{ - i32 458798, ;; Tag +!6 = metadata !{ + i32 524334, ;; Tag i32 0, ;; Unused metadata !1, ;; Context metadata !"main", ;; Name metadata !"main", ;; Display name metadata !"main", ;; Linkage name - metadata !1, ;; Compile unit + metadata !1, ;; File i32 1, ;; Line number - metadata !2, ;; Type + metadata !4, ;; Type i1 false, ;; Is local i1 true ;; Is definition } @@ -1188,10 +1212,10 @@ define i32 @main(i32 %argc, i8** %argv)
             !2 = metadata !{
            -  i32 458788,        ;; Tag
            +  i32 524324,        ;; Tag
               metadata !1,       ;; Context
               metadata !"bool",  ;; Name
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 0,             ;; Line number
               i64 8,             ;; Size in Bits
               i64 8,             ;; Align in Bits
            @@ -1214,10 +1238,10 @@ define i32 @main(i32 %argc, i8** %argv) 
             
             !2 = metadata !{
            -  i32 458788,        ;; Tag
            +  i32 524324,        ;; Tag
               metadata !1,       ;; Context
               metadata !"char",  ;; Name
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 0,             ;; Line number
               i64 8,             ;; Size in Bits
               i64 8,             ;; Align in Bits
            @@ -1240,10 +1264,10 @@ define i32 @main(i32 %argc, i8** %argv) 
             
             !2 = metadata !{
            -  i32 458788,        ;; Tag
            +  i32 524324,        ;; Tag
               metadata !1,       ;; Context
               metadata !"unsigned char", 
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 0,             ;; Line number
               i64 8,             ;; Size in Bits
               i64 8,             ;; Align in Bits
            @@ -1266,10 +1290,10 @@ define i32 @main(i32 %argc, i8** %argv) 
             
             !2 = metadata !{
            -  i32 458788,        ;; Tag
            +  i32 524324,        ;; Tag
               metadata !1,       ;; Context
               metadata !"short int",
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 0,             ;; Line number
               i64 16,            ;; Size in Bits
               i64 16,            ;; Align in Bits
            @@ -1292,10 +1316,10 @@ define i32 @main(i32 %argc, i8** %argv) 
             
             !2 = metadata !{
            -  i32 458788,        ;; Tag
            +  i32 524324,        ;; Tag
               metadata !1,       ;; Context
               metadata !"short unsigned int",
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 0,             ;; Line number
               i64 16,            ;; Size in Bits
               i64 16,            ;; Align in Bits
            @@ -1318,10 +1342,10 @@ define i32 @main(i32 %argc, i8** %argv) 
             
             !2 = metadata !{
            -  i32 458788,        ;; Tag
            +  i32 524324,        ;; Tag
               metadata !1,       ;; Context
               metadata !"int",   ;; Name
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 0,             ;; Line number
               i64 32,            ;; Size in Bits
               i64 32,            ;; Align in Bits
            @@ -1343,10 +1367,10 @@ define i32 @main(i32 %argc, i8** %argv) 
             
             !2 = metadata !{
            -  i32 458788,        ;; Tag
            +  i32 524324,        ;; Tag
               metadata !1,       ;; Context
               metadata !"unsigned int",
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 0,             ;; Line number
               i64 32,            ;; Size in Bits
               i64 32,            ;; Align in Bits
            @@ -1369,10 +1393,10 @@ define i32 @main(i32 %argc, i8** %argv) 
             
             !2 = metadata !{
            -  i32 458788,        ;; Tag
            +  i32 524324,        ;; Tag
               metadata !1,       ;; Context
               metadata !"long long int",
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 0,             ;; Line number
               i64 64,            ;; Size in Bits
               i64 64,            ;; Align in Bits
            @@ -1395,10 +1419,10 @@ define i32 @main(i32 %argc, i8** %argv) 
             
             !2 = metadata !{
            -  i32 458788,        ;; Tag
            +  i32 524324,        ;; Tag
               metadata !1,       ;; Context
               metadata !"long long unsigned int",
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 0,             ;; Line number
               i64 64,            ;; Size in Bits
               i64 64,            ;; Align in Bits
            @@ -1421,10 +1445,10 @@ define i32 @main(i32 %argc, i8** %argv) 
             
             !2 = metadata !{
            -  i32 458788,        ;; Tag
            +  i32 524324,        ;; Tag
               metadata !1,       ;; Context
               metadata !"float",
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 0,             ;; Line number
               i64 32,            ;; Size in Bits
               i64 32,            ;; Align in Bits
            @@ -1447,10 +1471,10 @@ define i32 @main(i32 %argc, i8** %argv) 
             
             !2 = metadata !{
            -  i32 458788,        ;; Tag
            +  i32 524324,        ;; Tag
               metadata !1,       ;; Context
               metadata !"double",;; Name
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 0,             ;; Line number
               i64 64,            ;; Size in Bits
               i64 64,            ;; Align in Bits
            @@ -1486,10 +1510,10 @@ typedef const int *IntPtr;
             ;; Define the typedef "IntPtr".
             ;;
             !2 = metadata !{
            -  i32 458774,          ;; Tag
            +  i32 524310,          ;; Tag
               metadata !1,         ;; Context
               metadata !"IntPtr",  ;; Name
            -  metadata !3,         ;; Compile unit
            +  metadata !3,         ;; File
               i32 0,               ;; Line number
               i64 0,               ;; Size in bits
               i64 0,               ;; Align in bits
            @@ -1502,10 +1526,10 @@ typedef const int *IntPtr;
             ;; Define the pointer type.
             ;;
             !4 = metadata !{
            -  i32 458767,          ;; Tag
            +  i32 524303,          ;; Tag
               metadata !1,         ;; Context
               metadata !"",        ;; Name
            -  metadata !1,         ;; Compile unit
            +  metadata !1,         ;; File
               i32 0,               ;; Line number
               i64 64,              ;; Size in bits
               i64 64,              ;; Align in bits
            @@ -1517,10 +1541,10 @@ typedef const int *IntPtr;
             ;; Define the const type.
             ;;
             !5 = metadata !{
            -  i32 458790,          ;; Tag
            +  i32 524326,          ;; Tag
               metadata !1,         ;; Context
               metadata !"",        ;; Name
            -  metadata !1,         ;; Compile unit
            +  metadata !1,         ;; File
               i32 0,               ;; Line number
               i64 32,              ;; Size in bits
               i64 32,              ;; Align in bits
            @@ -1532,10 +1556,10 @@ typedef const int *IntPtr;
             ;; Define the int type.
             ;;
             !6 = metadata !{
            -  i32 458788,          ;; Tag
            +  i32 524324,          ;; Tag
               metadata !1,         ;; Context
               metadata !"int",     ;; Name
            -  metadata !1,         ;; Compile unit
            +  metadata !1,         ;; File
               i32 0,               ;; Line number
               i64 32,              ;; Size in bits
               i64 32,              ;; Align in bits
            @@ -1575,10 +1599,10 @@ struct Color {
             ;; Define basic type for unsigned int.
             ;;
             !5 = metadata !{
            -  i32 458788,        ;; Tag
            +  i32 524324,        ;; Tag
               metadata !1,       ;; Context
               metadata !"unsigned int",
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 0,             ;; Line number
               i64 32,            ;; Size in Bits
               i64 32,            ;; Align in Bits
            @@ -1590,7 +1614,7 @@ struct Color {
             ;; Define composite type for struct Color.
             ;;
             !2 = metadata !{
            -  i32 458771,        ;; Tag
            +  i32 524307,        ;; Tag
               metadata !1,       ;; Context
               metadata !"Color", ;; Name
               metadata !1,       ;; Compile unit
            @@ -1608,10 +1632,10 @@ struct Color {
             ;; Define the Red field.
             ;;
             !4 = metadata !{
            -  i32 458765,        ;; Tag
            +  i32 524301,        ;; Tag
               metadata !1,       ;; Context
               metadata !"Red",   ;; Name
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 2,             ;; Line number
               i64 32,            ;; Size in bits
               i64 32,            ;; Align in bits
            @@ -1624,10 +1648,10 @@ struct Color {
             ;; Define the Green field.
             ;;
             !6 = metadata !{
            -  i32 458765,        ;; Tag
            +  i32 524301,        ;; Tag
               metadata !1,       ;; Context
               metadata !"Green", ;; Name
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 3,             ;; Line number
               i64 32,            ;; Size in bits
               i64 32,            ;; Align in bits
            @@ -1640,10 +1664,10 @@ struct Color {
             ;; Define the Blue field.
             ;;
             !7 = metadata !{
            -  i32 458765,        ;; Tag
            +  i32 524301,        ;; Tag
               metadata !1,       ;; Context
               metadata !"Blue",  ;; Name
            -  metadata !1,       ;; Compile Unit
            +  metadata !1,       ;; File
               i32 4,             ;; Line number
               i64 32,            ;; Size in bits
               i64 32,            ;; Align in bits
            @@ -1688,10 +1712,10 @@ enum Trees {
             ;; Define composite type for enum Trees
             ;;
             !2 = metadata !{
            -  i32 458756,        ;; Tag
            +  i32 524292,        ;; Tag
               metadata !1,       ;; Context
               metadata !"Trees", ;; Name
            -  metadata !1,       ;; Compile unit
            +  metadata !1,       ;; File
               i32 1,             ;; Line number
               i64 32,            ;; Size in bits
               i64 32,            ;; Align in bits
            @@ -1710,17 +1734,17 @@ enum Trees {
             ;;
             ;; Define Spruce enumerator.
             ;;
            -!4 = metadata !{i32 458792, metadata !"Spruce", i64 100}
            +!4 = metadata !{i32 524328, metadata !"Spruce", i64 100}
             
             ;;
             ;; Define Oak enumerator.
             ;;
            -!5 = metadata !{i32 458792, metadata !"Oak", i64 200}
            +!5 = metadata !{i32 524328, metadata !"Oak", i64 200}
             
             ;;
             ;; Define Maple enumerator.
             ;;
            -!6 = metadata !{i32 458792, metadata !"Maple", i64 300}
            +!6 = metadata !{i32 524328, metadata !"Maple", i64 300}
             
             
            @@ -1738,7 +1762,7 @@ enum Trees { Chris Lattner
            LLVM Compiler Infrastructure
            - Last modified: $Date: 2010-01-11 23:53:48 +0100 (Mon, 11 Jan 2010) $ + Last modified: $Date: 2010-03-09 01:44:10 +0100 (Tue, 09 Mar 2010) $ Modified: vendor/llvm/dist/docs/WritingAnLLVMPass.html ============================================================================== --- vendor/llvm/dist/docs/WritingAnLLVMPass.html Wed Mar 10 17:27:09 2010 (r204960) +++ vendor/llvm/dist/docs/WritingAnLLVMPass.html Wed Mar 10 17:45:15 2010 (r204961) @@ -909,16 +909,22 @@ finalization.

            A MachineFunctionPass is a part of the LLVM code generator that executes on the machine-dependent representation of each LLVM function in the -program. A MachineFunctionPass is also a FunctionPass, so all +program.

            + +

            Code generator passes are registered and initialized specially by +TargetMachine::addPassesToEmitFile and similar routines, so they +cannot generally be run from the opt or bugpoint +commands.

            + +

            A MachineFunctionPass is also a FunctionPass, so all the restrictions that apply to a FunctionPass also apply to it. MachineFunctionPasses also have additional restrictions. In particular, MachineFunctionPasses are not allowed to do any of the following:

              -
            1. Modify any LLVM Instructions, BasicBlocks or Functions.
            2. +
            3. Modify or create any LLVM IR Instructions, BasicBlocks, Arguments, + Functions, GlobalVariables, GlobalAliases, or Modules.
            4. Modify a MachineFunction other than the one currently being processed.
            5. -
            6. Add or remove MachineFunctions from the current Module.
            7. -
            8. Add or remove global variables from the current Module.
            9. Maintain state across invocations of runOnMachineFunction (including global data)
            10. @@ -1829,7 +1835,7 @@ Despite that, we have kept the LLVM pass Chris Lattner
              The LLVM Compiler Infrastructure
              - Last modified: $Date: 2010-02-18 15:37:52 +0100 (Thu, 18 Feb 2010) $ + Last modified: $Date: 2010-03-10 02:29:39 +0100 (Wed, 10 Mar 2010) $ Modified: vendor/llvm/dist/docs/tutorial/OCamlLangImpl3.html ============================================================================== --- vendor/llvm/dist/docs/tutorial/OCamlLangImpl3.html Wed Mar 10 17:27:09 2010 (r204960) +++ vendor/llvm/dist/docs/tutorial/OCamlLangImpl3.html Wed Mar 10 17:45:15 2010 (r204961) @@ -98,6 +98,7 @@ exception Error of string let the_module = create_module (global_context ()) "my cool jit" let builder = builder (global_context ()) let named_values:(string, llvalue) Hashtbl.t = Hashtbl.create 10 +let double_type = double_type context
            @@ -389,7 +390,7 @@ that there is an LLVM Function object th
                   (* Create a new basic block to start insertion into. *)
            -      let bb = append_block "entry" the_function in
            +      let bb = append_block context "entry" the_function in
                   position_at_end bb builder;
             
                   try
            @@ -903,6 +904,7 @@ let context = global_context ()
             let the_module = create_module context "my cool jit"
             let builder = builder context
             let named_values:(string, llvalue) Hashtbl.t = Hashtbl.create 10
            +let double_type = double_type context
             
             let rec codegen_expr = function
               | Ast.Number n -> const_float double_type n
            @@ -974,7 +976,7 @@ let codegen_func = function
                   let the_function = codegen_proto proto in
             
                   (* Create a new basic block to start insertion into. *)
            -      let bb = append_block "entry" the_function in
            +      let bb = append_block context "entry" the_function in
                   position_at_end bb builder;
             
                   try
            @@ -1085,7 +1087,7 @@ main ()
               Chris Lattner
            Erick Tryzelaar
            The LLVM Compiler Infrastructure
            - Last modified: $Date: 2010-03-02 02:11:08 +0100 (Tue, 02 Mar 2010) $ + Last modified: $Date: 2010-03-08 20:32:18 +0100 (Mon, 08 Mar 2010) $ Modified: vendor/llvm/dist/docs/tutorial/OCamlLangImpl4.html ============================================================================== --- vendor/llvm/dist/docs/tutorial/OCamlLangImpl4.html Wed Mar 10 17:27:09 2010 (r204960) +++ vendor/llvm/dist/docs/tutorial/OCamlLangImpl4.html Wed Mar 10 17:45:15 2010 (r204961) @@ -186,9 +186,8 @@ add a set of optimizations to run. The
               (* Create the JIT. *)
            -  let the_module_provider = ModuleProvider.create Codegen.the_module in
            -  let the_execution_engine = ExecutionEngine.create the_module_provider in
            -  let the_fpm = PassManager.create_function the_module_provider in
            +  let the_execution_engine = ExecutionEngine.create Codegen.the_module in
            +  let the_fpm = PassManager.create_function Codegen.the_module in
             
               (* Set up the optimizer pipeline.  Start with registering info about how the
                * target lays out data structures. *)
            @@ -213,18 +212,11 @@ add a set of optimizations to run.  The 
             
            -

            This code defines two values, an Llvm.llmoduleprovider and a -Llvm.PassManager.t. The former is basically a wrapper around our -Llvm.llmodule that the Llvm.PassManager.t requires. It -provides certain flexibility that we're not going to take advantage of here, -so I won't dive into any details about it.

            -

            The meat of the matter here, is the definition of "the_fpm". It -requires a pointer to the the_module (through the -the_module_provider) to construct itself. Once it is set up, we use a -series of "add" calls to add a bunch of LLVM passes. The first pass is -basically boilerplate, it adds a pass so that later optimizations know how the -data structures in the program are laid out. The +requires a pointer to the the_module to construct itself. Once it is +set up, we use a series of "add" calls to add a bunch of LLVM passes. The +first pass is basically boilerplate, it adds a pass so that later optimizations +know how the data structures in the program are laid out. The "the_execution_engine" variable is related to the JIT, which we will get to in the next section.

            *** DIFF OUTPUT TRUNCATED AT 1000 LINES ***