mirror of
				https://github.com/c64scene-ar/llvm-6502.git
				synced 2025-11-04 05:17:07 +00:00 
			
		
		
		
	Patch by Erick Tryzelaar. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48602 91177308-0d34-0410-b5e6-96231b3b80d8
		
			
				
	
	
		
			48 lines
		
	
	
		
			1.5 KiB
		
	
	
	
		
			C++
		
	
	
	
	
	
			
		
		
	
	
			48 lines
		
	
	
		
			1.5 KiB
		
	
	
	
		
			C++
		
	
	
	
	
	
//===-- Scalar.cpp --------------------------------------------------------===//
 | 
						|
//
 | 
						|
//                     The LLVM Compiler Infrastructure
 | 
						|
//
 | 
						|
// This file is distributed under the University of Illinois Open Source
 | 
						|
// License. See LICENSE.TXT for details.
 | 
						|
//
 | 
						|
//===----------------------------------------------------------------------===//
 | 
						|
//
 | 
						|
// This file implements the C bindings for libLLVMScalarOpts.a, which implements
 | 
						|
// several scalar transformations over the LLVM intermediate representation.
 | 
						|
//
 | 
						|
//===----------------------------------------------------------------------===//
 | 
						|
 | 
						|
#include "llvm-c/Transforms/Scalar.h"
 | 
						|
#include "llvm/PassManager.h"
 | 
						|
#include "llvm/Transforms/Scalar.h"
 | 
						|
 | 
						|
using namespace llvm;
 | 
						|
 | 
						|
void LLVMAddConstantPropagationPass(LLVMPassManagerRef PM) {
 | 
						|
  unwrap(PM)->add(createConstantPropagationPass());
 | 
						|
}
 | 
						|
 | 
						|
void LLVMAddInstructionCombiningPass(LLVMPassManagerRef PM) {
 | 
						|
  unwrap(PM)->add(createInstructionCombiningPass());
 | 
						|
}
 | 
						|
 | 
						|
void LLVMAddPromoteMemoryToRegisterPass(LLVMPassManagerRef PM) {
 | 
						|
  unwrap(PM)->add(createPromoteMemoryToRegisterPass());
 | 
						|
}
 | 
						|
 | 
						|
void LLVMAddDemoteMemoryToRegisterPass(LLVMPassManagerRef PM) {
 | 
						|
  unwrap(PM)->add(createDemoteRegisterToMemoryPass());
 | 
						|
}
 | 
						|
 | 
						|
void LLVMAddReassociatePass(LLVMPassManagerRef PM) {
 | 
						|
  unwrap(PM)->add(createReassociatePass());
 | 
						|
}
 | 
						|
 | 
						|
void LLVMAddGVNPass(LLVMPassManagerRef PM) {
 | 
						|
  unwrap(PM)->add(createGVNPass());
 | 
						|
}
 | 
						|
 | 
						|
void LLVMAddCFGSimplificationPass(LLVMPassManagerRef PM) {
 | 
						|
  unwrap(PM)->add(createCFGSimplificationPass());
 | 
						|
}
 |