Changeset 31f4837 for src/Common
- Timestamp:
- May 13, 2024, 10:26:59 AM (17 months ago)
- Branches:
- master
- Children:
- e6f1a4b
- Parents:
- acb33f15 (diff), ca4f2b2 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - Location:
- src/Common
- Files:
-
- 4 edited
- 30 moved
Legend:
- Unmodified
- Added
- Removed
-
src/Common/Assert.cpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Assert.c c--7 // Assert.cpp -- 8 8 // 9 9 // Author : Peter A. Buhr … … 22 22 #define CFA_ASSERT_FMT "*CFA assertion error* \"%s\" from program \"%s\" in \"%s\" at line %d in file \"%s\"" 23 23 24 // called by macro assert in assert.h24 // called by macro assert in cassert 25 25 void __assert_fail( const char *assertion, const char *file, unsigned int line, const char *function ) { 26 26 fprintf( stderr, CFA_ASSERT_FMT ".\n", assertion, __progname, function, line, file ); -
src/Common/CodeLocation.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // CodeLocation.h --7 // CodeLocation.hpp -- 8 8 // 9 9 // Author : Andrew Beach -
src/Common/CodeLocationTools.cpp
racb33f15 r31f4837 20 20 #include "AST/Pass.hpp" 21 21 #include "AST/TranslationUnit.hpp" 22 #include "Common/CodeLocation.h "22 #include "Common/CodeLocation.hpp" 23 23 24 24 namespace { -
src/Common/DeclStats.cpp
racb33f15 r31f4837 19 19 #include "AST/Pass.hpp" 20 20 #include "AST/Print.hpp" 21 #include "Common/VectorMap.h "21 #include "Common/VectorMap.hpp" 22 22 23 23 #include <iostream> -
src/Common/ErrorObjects.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // ErrorObjects.h --7 // ErrorObjects.hpp -- 8 8 // 9 9 // Author : Thierry Delisle … … 23 23 #include <unistd.h> // for isatty 24 24 25 #include "CodeLocation.h " // for CodeLocation, toString25 #include "CodeLocation.hpp" // for CodeLocation, toString 26 26 27 27 struct error { -
src/Common/Eval.cpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Eval.c c-- Evaluate parts of the ast at compile time.7 // Eval.cpp -- Evaluate parts of the ast at compile time. 8 8 // 9 9 // Author : Richard C. Bilson … … 14 14 // 15 15 16 #include "Eval.h "16 #include "Eval.hpp" 17 17 18 18 #include <utility> // for pair 19 19 20 20 #include "AST/Inspect.hpp" 21 #include "CodeGen/OperatorTable.h " // access: OperatorInfo21 #include "CodeGen/OperatorTable.hpp" // access: OperatorInfo 22 22 #include "AST/Pass.hpp" 23 #include "InitTweak/InitTweak.h "23 #include "InitTweak/InitTweak.hpp" 24 24 25 25 struct EvalNew : public ast::WithShortCircuiting { -
src/Common/Eval.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Eval.h -- Evaluate parts of the ast at compile time.7 // Eval.hpp -- Evaluate parts of the ast at compile time. 8 8 // 9 9 // Author : Andrew Beach -
src/Common/Examine.cpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Examine.c c-- Helpers for examining AST code.7 // Examine.cpp -- Helpers for examining AST code. 8 8 // 9 9 // Author : Andrew Beach … … 14 14 // 15 15 16 #include "Common/Examine.h "16 #include "Common/Examine.hpp" 17 17 18 18 #include "AST/Type.hpp" 19 #include "CodeGen/OperatorTable.h "20 #include "InitTweak/InitTweak.h "19 #include "CodeGen/OperatorTable.hpp" 20 #include "InitTweak/InitTweak.hpp" 21 21 22 22 namespace { … … 55 55 const ast::Type * getDestructorParam( const ast::FunctionDecl * func ) { 56 56 if ( !CodeGen::isDestructor( func->name ) ) return nullptr; 57 //return InitTweak::getParamThis( func )->type;58 57 return getTypeofThisSolo( func ); 59 58 } -
src/Common/Examine.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Examine.h -- Helpers for examining AST code.7 // Examine.hpp -- Helpers for examining AST code. 8 8 // 9 9 // Author : Andrew Beach -
src/Common/FilterCombos.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // FilterCombos.h --7 // FilterCombos.hpp -- 8 8 // 9 9 // Author : Aaron B. Moss … … 22 22 23 23 /// Combo iterator that simply collects values into a vector, marking all values as valid. 24 /// Prefer combos in typeops.hto use of IntoVectorComboIter with filterCombos24 /// Prefer combos in Typeops.hpp to use of IntoVectorComboIter with filterCombos 25 25 /// @param T The element type of the vector. 26 26 template<typename T> -
src/Common/Indenter.cpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Indenter.c c--7 // Indenter.cpp -- 8 8 // 9 9 // Author : Andrew Beach … … 14 14 // 15 15 16 #include "Indenter.h "16 #include "Indenter.hpp" 17 17 18 18 unsigned Indenter::tabsize = 2; -
src/Common/Indenter.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Indenter.h --7 // Indenter.hpp -- 8 8 // 9 9 // Author : Rob Schluntz -
src/Common/PersistentMap.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // PersistentMap.h --7 // PersistentMap.hpp -- 8 8 // 9 9 // Author : Aaron B. Moss -
src/Common/ResolvProtoDump.cpp
racb33f15 r31f4837 26 26 #include "AST/TranslationUnit.hpp" 27 27 #include "AST/Type.hpp" 28 #include "CodeGen/OperatorTable.h "28 #include "CodeGen/OperatorTable.hpp" 29 29 30 30 namespace { -
src/Common/ScopedMap.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // ScopedMap.h --7 // ScopedMap.hpp -- 8 8 // 9 9 // Author : Aaron B. Moss -
src/Common/SemanticError.cpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // SemanticError.c c--7 // SemanticError.cpp -- 8 8 // 9 9 // Author : Thierry Delisle … … 13 13 // Update Count : 34 14 14 // 15 16 #include "SemanticError.hpp" 15 17 16 18 #include <cstdarg> … … 23 25 #include <vector> 24 26 27 #include "Common/Utility.hpp" // for to_string, CodeLocation (ptr only) 28 25 29 using namespace std; 26 27 #include "Common/utility.h" // for to_string, CodeLocation (ptr only)28 #include "SemanticError.h"29 30 30 31 //----------------------------------------------------------------------------- -
src/Common/SemanticError.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // SemanticError.h --7 // SemanticError.hpp -- 8 8 // 9 9 // Author : Thierry Delisle … … 16 16 #pragma once 17 17 18 #include "ErrorObjects.h "18 #include "ErrorObjects.hpp" 19 19 #include "AST/Node.hpp" 20 20 #include "AST/ParseNode.hpp" -
src/Common/Stats.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Stats.h --7 // Stats.hpp -- 8 8 // 9 9 // Author : Thierry Delisle … … 24 24 25 25 These can be enabled using the --stats option, to which a comma seperated list of options can be passed. 26 For more details see Stats.cc26 For more information, see Stats/Stats.cpp 27 27 28 28 Counters: … … 40 40 41 41 42 #include "Common/Stats/Counter.h "43 #include "Common/Stats/Heap.h "44 #include "Common/Stats/Time.h "42 #include "Common/Stats/Counter.hpp" 43 #include "Common/Stats/Heap.hpp" 44 #include "Common/Stats/Time.hpp" 45 45 46 46 namespace Stats { -
src/Common/Stats/Base.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Heap.h --7 // Heap.hpp -- 8 8 // 9 9 // Author : Thierry Delisle -
src/Common/Stats/Counter.cpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Counter.c c--7 // Counter.cpp -- 8 8 // 9 9 // Author : Thierry Delisle … … 14 14 // 15 15 16 #include "Counter.h "16 #include "Counter.hpp" 17 17 18 18 #include <algorithm> -
src/Common/Stats/Counter.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Counter.h --7 // Counter.hpp -- 8 8 // 9 9 // Author : Thierry Delisle … … 19 19 #include <iostream> 20 20 21 #include "Common/Stats/Base.h "21 #include "Common/Stats/Base.hpp" 22 22 23 23 #if defined( NO_STATISTICS ) -
src/Common/Stats/Heap.cpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Heap.c c--7 // Heap.cpp -- 8 8 // 9 9 // Author : Thierry Delisle … … 69 69 void stacktrace_push(size_t id) { 70 70 ++stacktrace_depth; 71 assertf(stacktrace_depth < stacktrace_max_depth, "Stack trace too deep: increase size of array in Heap.c c");71 assertf(stacktrace_depth < stacktrace_max_depth, "Stack trace too deep: increase size of array in Heap.cpp"); 72 72 trace[stacktrace_depth] = id; 73 73 } … … 87 87 passes_cnt++; 88 88 89 assertf(passes_cnt < passes_size, "Too many passes for Stats::Heap, increase the size of the array in Heap.c c");89 assertf(passes_cnt < passes_size, "Too many passes for Stats::Heap, increase the size of the array in Heap.cpp"); 90 90 } 91 91 -
src/Common/Stats/Heap.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Heap.h --7 // Heap.hpp -- 8 8 // 9 9 // Author : Thierry Delisle -
src/Common/Stats/ResolveTime.cpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // ResolveTime.c c--7 // ResolveTime.cpp -- 8 8 // 9 9 // Author : Thierry Delisle … … 14 14 // 15 15 16 #include "ResolveTime.h "16 #include "ResolveTime.hpp" 17 17 18 18 #include <fstream> -
src/Common/Stats/ResolveTime.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // ResolveTime.h --7 // ResolveTime.hpp -- 8 8 // 9 9 // Author : Thierry Delisle … … 16 16 #pragma once 17 17 18 #include "Common/Stats/Base.h "18 #include "Common/Stats/Base.hpp" 19 19 20 20 #if defined( NO_STATISTICS ) -
src/Common/Stats/Stats.cpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Stats.c c--7 // Stats.cpp -- 8 8 // 9 9 // Author : Thierry Delisle -
src/Common/Stats/Time.cpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Time.c c--7 // Time.cpp -- 8 8 // 9 9 // Author : Thierry Delisle … … 14 14 // 15 15 16 #include "Time.h "16 #include "Time.hpp" 17 17 18 18 #include <cassert> -
src/Common/Stats/Time.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // Time.h --7 // Time.hpp -- 8 8 // 9 9 // Author : Thierry Delisle … … 16 16 #pragma once 17 17 18 #include "Common/Stats/Base.h "18 #include "Common/Stats/Base.hpp" 19 19 20 20 #if defined( NO_STATISTICS ) -
src/Common/UniqueName.cpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // UniqueName.c c-- Create a unique variants of a base name with a counter.7 // UniqueName.cpp -- Create a unique variants of a base name with a counter. 8 8 // 9 9 // Author : Richard C. Bilson … … 14 14 // 15 15 16 #include "UniqueName.h "16 #include "UniqueName.hpp" 17 17 18 18 #include "Common/ToString.hpp" -
src/Common/UniqueName.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // UniqueName.h -- Create a unique variants of a base name with a counter.7 // UniqueName.hpp -- Create a unique variants of a base name with a counter. 8 8 // 9 9 // Author : Richard C. Bilson -
src/Common/Utility.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // utility.h-- General utilities used across the compiler.7 // Utility.hpp -- General utilities used across the compiler. 8 8 // 9 9 // Author : Richard C. Bilson -
src/Common/VectorMap.hpp
racb33f15 r31f4837 5 5 // file "LICENCE" distributed with Cforall. 6 6 // 7 // VectorMap.h --7 // VectorMap.hpp -- 8 8 // 9 9 // Author : Aaron B. Moss -
src/Common/module.mk
racb33f15 r31f4837 16 16 17 17 SRC_COMMON = \ 18 Common/Assert.c c\19 Common/CodeLocation.h \18 Common/Assert.cpp \ 19 Common/CodeLocation.hpp \ 20 20 Common/CodeLocationTools.hpp \ 21 21 Common/CodeLocationTools.cpp \ 22 22 Common/DeclStats.hpp \ 23 23 Common/DeclStats.cpp \ 24 Common/ErrorObjects.h \25 Common/Eval.c c\26 Common/Eval.h \27 Common/Examine.c c\28 Common/Examine.h \29 Common/FilterCombos.h \30 Common/Indenter.h \31 Common/Indenter.c c\24 Common/ErrorObjects.hpp \ 25 Common/Eval.cpp \ 26 Common/Eval.hpp \ 27 Common/Examine.cpp \ 28 Common/Examine.hpp \ 29 Common/FilterCombos.hpp \ 30 Common/Indenter.hpp \ 31 Common/Indenter.cpp \ 32 32 Common/Iterate.hpp \ 33 Common/PersistentMap.h \33 Common/PersistentMap.hpp \ 34 34 Common/ResolvProtoDump.hpp \ 35 35 Common/ResolvProtoDump.cpp \ 36 Common/ScopedMap.h \37 Common/SemanticError.c c\38 Common/SemanticError.h \39 Common/Stats.h \40 Common/Stats/Base.h \41 Common/Stats/Counter.c c\42 Common/Stats/Counter.h \43 Common/Stats/Heap.c c\44 Common/Stats/Heap.h \45 Common/Stats/ResolveTime.c c\46 Common/Stats/ResolveTime.h \47 Common/Stats/Stats.c c\48 Common/Stats/Time.c c\49 Common/Stats/Time.h \36 Common/ScopedMap.hpp \ 37 Common/SemanticError.cpp \ 38 Common/SemanticError.hpp \ 39 Common/Stats.hpp \ 40 Common/Stats/Base.hpp \ 41 Common/Stats/Counter.cpp \ 42 Common/Stats/Counter.hpp \ 43 Common/Stats/Heap.cpp \ 44 Common/Stats/Heap.hpp \ 45 Common/Stats/ResolveTime.cpp \ 46 Common/Stats/ResolveTime.hpp \ 47 Common/Stats/Stats.cpp \ 48 Common/Stats/Time.cpp \ 49 Common/Stats/Time.hpp \ 50 50 Common/ToString.hpp \ 51 Common/UniqueName.c c\52 Common/UniqueName.h \53 Common/ utility.h\54 Common/VectorMap.h 51 Common/UniqueName.cpp \ 52 Common/UniqueName.hpp \ 53 Common/Utility.hpp \ 54 Common/VectorMap.hpp 55 55 56 56 SRC += $(SRC_COMMON) \ 57 Common/DebugMalloc.c c57 Common/DebugMalloc.cpp 58 58 59 59 SRCDEMANGLE += $(SRC_COMMON)
Note:
See TracChangeset
for help on using the changeset viewer.