Skip to content

Commit

Permalink
blah
Browse files Browse the repository at this point in the history
  • Loading branch information
ragusaa committed Jan 19, 2024
1 parent c7133f4 commit 65414fd
Show file tree
Hide file tree
Showing 54 changed files with 139 additions and 134 deletions.
2 changes: 2 additions & 0 deletions libclambcc/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Copyright (C) 2021 Cisco Systems, Inc. and/or its affiliates. All rights reserved.


set (CLAMBC_LIB_DIR ${CMAKE_CURRENT_SOURCE_DIR})

add_subdirectory(ClamBCLogicalCompiler)
add_subdirectory(ClamBCLogicalCompilerHelper)
#add_subdirectory(ClamBCRemoveUndefs)
Expand Down
6 changes: 3 additions & 3 deletions libclambcc/ClamBCAnalyzer/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ target_sources(clambcanalyzer_obj

target_include_directories(clambcanalyzer_obj
PRIVATE
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
. # For Common/clambc.h
.. # For clambc.h #TODO: change all passes to use "Common" and then delete this line.
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
..
${CLAMBC_LIB_DIR}/Common # For anything in 'Common'
${LLVM_INCLUDE_DIRS}
)

Expand Down
5 changes: 3 additions & 2 deletions libclambcc/ClamBCAnalyzer/ClamBCAnalyzer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,9 @@
* MA 02110-1301, USA.
*/
#include "ClamBCAnalyzer.h"
#include "Common/ClamBCCommon.h"
#include "Common/ClamBCUtilities.h"

#include "ClamBCCommon.h"
#include "ClamBCUtilities.h"

#include <llvm/IR/Dominators.h>
#include <llvm/IR/DerivedTypes.h>
Expand Down
2 changes: 1 addition & 1 deletion libclambcc/ClamBCAnalyzer/ClamBCAnalyzer.h
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
#ifndef CLAMBC_ANALYZER_H_
#define CLAMBC_ANALYZER_H_

#include "Common/clambc.h"
#include "clambc.h"

#include <llvm/ADT/DenseMap.h>
#include <llvm/ADT/DenseSet.h>
Expand Down
4 changes: 2 additions & 2 deletions libclambcc/ClamBCChangeMallocArgSize/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ target_sources(clambcchangemallocargsize_obj
target_include_directories(clambcchangemallocargsize_obj
PRIVATE
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
. # For Common/clambc.h
.. # For clambc.h #TODO: change all passes to use "Common" and then delete this line.
..
${CLAMBC_LIB_DIR}/Common # For anything in 'Common'
${LLVM_INCLUDE_DIRS}
)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "clambc.h"

#include <llvm/Pass.h>
#include <llvm/IR/Function.h>
Expand All @@ -11,7 +12,6 @@
#include <llvm/Passes/PassBuilder.h>
#include <llvm/Passes/PassPlugin.h>

#include "Common/clambc.h"

using namespace llvm;

Expand Down
4 changes: 2 additions & 2 deletions libclambcc/ClamBCConvertIntrinsicsTo32Bit/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ target_sources(clambcconvertintrinsicsto32bit_obj
target_include_directories(clambcconvertintrinsicsto32bit_obj
PRIVATE
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
. # For Common/clambc.h
.. # For clambc.h #TODO: change all passes to use "Common" and then delete this line.
..
${CLAMBC_LIB_DIR}/Common # For anything in 'Common'
${LLVM_INCLUDE_DIRS}
)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
#include "clambc.h"

#include <llvm/Pass.h>
#include <llvm/IR/Function.h>
Expand All @@ -14,7 +15,6 @@
#include <llvm/IR/Constants.h>
#include <llvm/Transforms/IPO/PassManagerBuilder.h>

#include "Common/clambc.h"

#include <vector>

Expand Down
4 changes: 2 additions & 2 deletions libclambcc/ClamBCExtendPHIsTo64Bit/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ target_sources(clambcextendphisto64bit_obj
target_include_directories(clambcextendphisto64bit_obj
PRIVATE
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
. # For Common/clambc.h
.. # For clambc.h #TODO: change all passes to use "Common" and then delete this line.
..
${CLAMBC_LIB_DIR}/Common # For anything in 'Common'
${LLVM_INCLUDE_DIRS}
)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
* MA 02110-1301, USA.
*/
#include "Common/bytecode_api.h"
#include "Common/clambc.h"
#include "Common/ClamBCUtilities.h"
#include "bytecode_api.h"
#include "clambc.h"
#include "ClamBCUtilities.h"

#include <llvm/Support/DataTypes.h>
#include <llvm/ADT/STLExtras.h>
Expand Down
4 changes: 2 additions & 2 deletions libclambcc/ClamBCLogicalCompiler/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ target_sources(clambclogicalcompiler_obj
target_include_directories(clambclogicalcompiler_obj
PRIVATE
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
. # For Common/clambc.h
.. # For clambc.h #TODO: change all passes to use "Common" and then delete this line.
..
${CLAMBC_LIB_DIR}/Common # For anything in 'Common'
${LLVM_INCLUDE_DIRS}
)

Expand Down
10 changes: 5 additions & 5 deletions libclambcc/ClamBCLogicalCompiler/ClamBCLogicalCompiler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@
* MA 02110-1301, USA.
*/

#include "Common/clambc.h"
#include "Common/bytecode_api.h"
#include "Common/ClamBCDiagnostics.h"
#include "Common/ClamBCCommon.h"
#include "Common/ClamBCUtilities.h"
#include "clambc.h"
#include "bytecode_api.h"
#include "ClamBCDiagnostics.h"
#include "ClamBCCommon.h"
#include "ClamBCUtilities.h"

#include <llvm/Support/DataTypes.h>
#include <llvm/ADT/FoldingSet.h>
Expand Down
4 changes: 2 additions & 2 deletions libclambcc/ClamBCLogicalCompilerHelper/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ target_sources(clambclogicalcompilerhelper_obj
target_include_directories(clambclogicalcompilerhelper_obj
PRIVATE
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
. # For Common/clambc.h
.. # For clambc.h #TODO: change all passes to use "Common" and then delete this line.
..
${CLAMBC_LIB_DIR}/Common # For anything in 'Common'
${LLVM_INCLUDE_DIRS}
)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@
* MA 02110-1301, USA.
*/

#include "Common/clambc.h"
#include "Common/bytecode_api.h"
#include "Common/ClamBCDiagnostics.h"
#include "Common/ClamBCCommon.h"
#include "Common/ClamBCUtilities.h"
#include "clambc.h"
#include "bytecode_api.h"
#include "ClamBCDiagnostics.h"
#include "ClamBCCommon.h"
#include "ClamBCUtilities.h"

#include <llvm/Support/DataTypes.h>
#include <llvm/ADT/FoldingSet.h>
Expand Down
8 changes: 4 additions & 4 deletions libclambcc/ClamBCLowering/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ target_sources(clambcloweringf_obj
target_include_directories(clambcloweringf_obj
PRIVATE
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
. # For Common/clambc.h
.. # For clambc.h #TODO: change all passes to use "Common" and then delete this line.
..
${CLAMBC_LIB_DIR}/Common # For anything in 'Common'
${LLVM_INCLUDE_DIRS}
)

Expand Down Expand Up @@ -58,8 +58,8 @@ target_sources(clambcloweringnf_obj
target_include_directories(clambcloweringnf_obj
PRIVATE
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
. # For Common/clambc.h
.. # For clambc.h #TODO: change all passes to use "Common" and then delete this line.
..
${CLAMBC_LIB_DIR}/Common # For anything in 'Common'
${LLVM_INCLUDE_DIRS}
)

Expand Down
2 changes: 1 addition & 1 deletion libclambcc/ClamBCLowering/ClamBCLowering.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
*/
#include "ClamBCLowering.h"

#include "Common/clambc.h"
#include "clambc.h"

#include <llvm/Passes/PassPlugin.h>
#include <llvm/IR/InstIterator.h>
Expand Down
2 changes: 1 addition & 1 deletion libclambcc/ClamBCLowering/ClamBCLoweringF.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

#include "ClamBCLowering.h"

#include "Common/clambc.h"
#include "clambc.h"

#include <llvm/Passes/PassPlugin.h>

Expand Down
2 changes: 1 addition & 1 deletion libclambcc/ClamBCLowering/ClamBCLoweringNF.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

#include "ClamBCLowering.h"

#include "Common/clambc.h"
#include "clambc.h"

#include <llvm/Passes/PassPlugin.h>

Expand Down
4 changes: 2 additions & 2 deletions libclambcc/ClamBCOutlineEndiannessCalls/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ target_sources(clambcoutlineendiannesscalls_obj
target_include_directories(clambcoutlineendiannesscalls_obj
PRIVATE
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
. # For Common/clambc.h
.. # For clambc.h #TODO: change all passes to use "Common" and then delete this line.
..
${CLAMBC_LIB_DIR}/Common # For anything in 'Common'
${LLVM_INCLUDE_DIRS}
)

Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@

#include "Common/clambc.h"
#include "clambc.h"

#include <llvm/Pass.h>
#include <llvm/IR/Function.h>
Expand Down
6 changes: 3 additions & 3 deletions libclambcc/ClamBCPrepareGEPsForWriter/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ target_sources(clambcpreparegepsforwriter_obj

target_include_directories(clambcpreparegepsforwriter_obj
PRIVATE
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
. # For Common/clambc.h
.. # For clambc.h #TODO: change all passes to use "Common" and then delete this line.
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
..
${CLAMBC_LIB_DIR}/Common # For anything in 'Common'
${LLVM_INCLUDE_DIRS}
)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,12 @@
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
* MA 02110-1301, USA.
*/
#include "Common/bytecode_api.h"
#include "Common/clambc.h"
#include "Common/ClamBCModule.h"
#include "bytecode_api.h"
#include "clambc.h"
#include "ClamBCModule.h"
#include "ClamBCUtilities.h"

#include "ClamBCAnalyzer/ClamBCAnalyzer.h"
#include "Common/ClamBCUtilities.h"

#include <llvm/Support/DataTypes.h>
#include <llvm/ADT/STLExtras.h>
Expand Down
4 changes: 2 additions & 2 deletions libclambcc/ClamBCPreserveABIs/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ target_sources(clambcpreserveabis_obj
target_include_directories(clambcpreserveabis_obj
PRIVATE
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
. # For Common/clambc.h
.. # For clambc.h #TODO: change all passes to use "Common" and then delete this line.
..
${CLAMBC_LIB_DIR}/Common # For anything in 'Common'
${LLVM_INCLUDE_DIRS}
)

Expand Down
7 changes: 3 additions & 4 deletions libclambcc/ClamBCPreserveABIs/ClamBCPreserveABIs.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@

#include "clambc.h"
#include "ClamBCUtilities.h"

#include <llvm/Pass.h>
#include "llvm/IR/Module.h"
#include "llvm/IR/Module.h"
Expand All @@ -7,14 +10,10 @@

#include <llvm/IR/Dominators.h>

//#include "llvm/IR/LegacyPassManager.h"
#include <llvm/Transforms/IPO/PassManagerBuilder.h>
#include <llvm/Passes/PassPlugin.h>
#include <llvm/Passes/PassBuilder.h>

#include "Common/clambc.h"
#include "Common/ClamBCUtilities.h"

#include <sstream>
#include <string>
using namespace llvm;
Expand Down
6 changes: 3 additions & 3 deletions libclambcc/ClamBCRebuild/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ target_sources(clambcrebuild_obj

target_include_directories(clambcrebuild_obj
PRIVATE
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
. # For Common/clambc.h
.. # For clambc.h #TODO: change all passes to use "Common" and then delete this line.
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
..
${CLAMBC_LIB_DIR}/Common # For anything in 'Common'
${LLVM_INCLUDE_DIRS}
)

Expand Down
6 changes: 3 additions & 3 deletions libclambcc/ClamBCRebuild/ClamBCRebuild.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@
* MA 02110-1301, USA.
*/

#include "Common/ClamBCModule.h"
#include "Common/clambc.h"
#include "Common/ClamBCUtilities.h"
#include "ClamBCModule.h"
#include "clambc.h"
#include "ClamBCUtilities.h"

#include <llvm/Support/DataTypes.h>
#include <llvm/ADT/DenseMap.h>
Expand Down
4 changes: 2 additions & 2 deletions libclambcc/ClamBCRegAlloc/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ target_sources(clambcregalloc_obj
target_include_directories(clambcregalloc_obj
PRIVATE
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
. # For Common/clambc.h
.. # For clambc.h #TODO: change all passes to use "Common" and then delete this line.
..
${CLAMBC_LIB_DIR}/Common # For anything in 'Common'
${LLVM_INCLUDE_DIRS}
)

Expand Down
6 changes: 2 additions & 4 deletions libclambcc/ClamBCRegAlloc/ClamBCRegAlloc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,10 @@
* MA 02110-1301, USA.
*/
#include "ClamBCRegAlloc.h"
#include "Common/ClamBCUtilities.h"
#include "Common/clambc.h"
#include "ClamBCUtilities.h"
#include "clambc.h"

#include <llvm/IR/Dominators.h>
//#include "llvm/Analysis/LiveValues.h"
//#include "llvm/Config/config.h"
#include <llvm/IR/DerivedTypes.h>
#include <llvm/IR/Instructions.h>
#include <llvm/IR/IntrinsicInst.h>
Expand Down
7 changes: 4 additions & 3 deletions libclambcc/ClamBCRegAlloc/ClamBCRegAlloc.h
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,9 @@
*/
#ifndef CLAMBC_REGALLOC_H
#define CLAMBC_REGALLOC_H
#include <cstddef>

#include "clambc.h"

#include <llvm/ADT/DenseMap.h>
#include <llvm/ADT/DenseSet.h>
#include <llvm/ADT/StringMap.h>
Expand All @@ -36,8 +38,7 @@

#include <vector>
#include <map>

#include "Common/clambc.h"
#include <cstddef>

class ClamBCRegAllocAnalysis
{
Expand Down
4 changes: 2 additions & 2 deletions libclambcc/ClamBCRemoveFSHL/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ target_sources(clambcremovefshl_obj
target_include_directories(clambcremovefshl_obj
PRIVATE
${CMAKE_BINARY_DIR} # For clambc-version.h (generated file)
. # For Common/clambc.h
.. # For clambc.h #TODO: change all passes to use "Common" and then delete this line.
..
${CLAMBC_LIB_DIR}/Common # For anything in 'Common'
${LLVM_INCLUDE_DIRS}
)

Expand Down
4 changes: 2 additions & 2 deletions libclambcc/ClamBCRemoveFSHL/ClamBCRemoveFSHL.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@
* MA 02110-1301, USA.
*/

#include "Common/clambc.h"
#include "Common/ClamBCUtilities.h"
#include "clambc.h"
#include "ClamBCUtilities.h"

#include <llvm/IR/Module.h>
#include <llvm/IR/Instructions.h>
Expand Down
Loading

0 comments on commit 65414fd

Please sign in to comment.