]> granicus.if.org Git - clang/commit
[Clang Interpreter] Initial patch for the constexpr interpreter
authorNandor Licker <n@ndor.email>
Fri, 30 Aug 2019 15:02:09 +0000 (15:02 +0000)
committerNandor Licker <n@ndor.email>
Fri, 30 Aug 2019 15:02:09 +0000 (15:02 +0000)
commitff0c62802f36635b42ee98b6de52106468031c73
tree90224bb888205200209d74c19f6dcdf47f2986fc
parent940667de80ecc16952d0add91261e565b9466f37
[Clang Interpreter] Initial patch for the constexpr interpreter

Summary:
This patch introduces the skeleton of the constexpr interpreter,
capable of evaluating a simple constexpr functions consisting of
if statements. The interpreter is described in more detail in the
RFC. Further patches will add more features.

Reviewers: Bigcheese, jfb, rsmith

Subscribers: bruno, uenoku, ldionne, Tyker, thegameg, tschuett, dexonsmith, mgorny, cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D64146

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@370476 91177308-0d34-0410-b5e6-96231b3b80d8
64 files changed:
docs/ConstantInterpreter.rst [new file with mode: 0644]
include/clang/AST/ASTContext.h
include/clang/Basic/DiagnosticASTKinds.td
include/clang/Basic/LangOptions.def
include/clang/Basic/OptionalDiagnostic.h [new file with mode: 0644]
include/clang/Driver/Options.td
lib/AST/ASTContext.cpp
lib/AST/CMakeLists.txt
lib/AST/ExprConstant.cpp
lib/AST/Interp/Block.cpp [new file with mode: 0644]
lib/AST/Interp/Block.h [new file with mode: 0644]
lib/AST/Interp/ByteCodeEmitter.cpp [new file with mode: 0644]
lib/AST/Interp/ByteCodeEmitter.h [new file with mode: 0644]
lib/AST/Interp/ByteCodeExprGen.cpp [new file with mode: 0644]
lib/AST/Interp/ByteCodeExprGen.h [new file with mode: 0644]
lib/AST/Interp/ByteCodeGenError.cpp [new file with mode: 0644]
lib/AST/Interp/ByteCodeGenError.h [new file with mode: 0644]
lib/AST/Interp/ByteCodeStmtGen.cpp [new file with mode: 0644]
lib/AST/Interp/ByteCodeStmtGen.h [new file with mode: 0644]
lib/AST/Interp/CMakeLists.txt [new file with mode: 0644]
lib/AST/Interp/Context.cpp [new file with mode: 0644]
lib/AST/Interp/Context.h [new file with mode: 0644]
lib/AST/Interp/Descriptor.cpp [new file with mode: 0644]
lib/AST/Interp/Descriptor.h [new file with mode: 0644]
lib/AST/Interp/Disasm.cpp [new file with mode: 0644]
lib/AST/Interp/EvalEmitter.cpp [new file with mode: 0644]
lib/AST/Interp/EvalEmitter.h [new file with mode: 0644]
lib/AST/Interp/Frame.cpp [new file with mode: 0644]
lib/AST/Interp/Frame.h [new file with mode: 0644]
lib/AST/Interp/Function.cpp [new file with mode: 0644]
lib/AST/Interp/Function.h [new file with mode: 0644]
lib/AST/Interp/Integral.h [new file with mode: 0644]
lib/AST/Interp/Interp.cpp [new file with mode: 0644]
lib/AST/Interp/Interp.h [new file with mode: 0644]
lib/AST/Interp/InterpFrame.cpp [new file with mode: 0644]
lib/AST/Interp/InterpFrame.h [new file with mode: 0644]
lib/AST/Interp/InterpStack.cpp [new file with mode: 0644]
lib/AST/Interp/InterpStack.h [new file with mode: 0644]
lib/AST/Interp/InterpState.cpp [new file with mode: 0644]
lib/AST/Interp/InterpState.h [new file with mode: 0644]
lib/AST/Interp/Opcode.h [new file with mode: 0644]
lib/AST/Interp/Opcodes.td [new file with mode: 0644]
lib/AST/Interp/Pointer.cpp [new file with mode: 0644]
lib/AST/Interp/Pointer.h [new file with mode: 0644]
lib/AST/Interp/Program.cpp [new file with mode: 0644]
lib/AST/Interp/Program.h [new file with mode: 0644]
lib/AST/Interp/Record.cpp [new file with mode: 0644]
lib/AST/Interp/Record.h [new file with mode: 0644]
lib/AST/Interp/Source.cpp [new file with mode: 0644]
lib/AST/Interp/Source.h [new file with mode: 0644]
lib/AST/Interp/State.cpp [new file with mode: 0644]
lib/AST/Interp/State.h [new file with mode: 0644]
lib/AST/Interp/Type.cpp [new file with mode: 0644]
lib/AST/Interp/Type.h [new file with mode: 0644]
lib/Driver/ToolChains/Clang.cpp
lib/Frontend/CompilerInvocation.cpp
test/AST/Interp/cond.cpp [new file with mode: 0644]
test/SemaCXX/constant-expression-cxx2a.cpp
test/SemaCXX/constexpr-many-arguments.cpp
test/SemaCXX/shift.cpp
utils/TableGen/CMakeLists.txt
utils/TableGen/ClangOpcodesEmitter.cpp [new file with mode: 0644]
utils/TableGen/TableGen.cpp
utils/TableGen/TableGenBackends.h