Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
ffa9906
LSP
mll Mar 9, 2026
f2aae80
Organise class descriptions.
mll Mar 10, 2026
1a524fa
Improve EdnParser
mll Mar 10, 2026
f68a434
Cleanup.
mll Mar 10, 2026
f14920f
Simplistic static call node.
mll Mar 10, 2026
32cdd0c
Complete the basic StaticCall
mll Mar 10, 2026
dbf0b42
Upgrades
mll Mar 10, 2026
0c5dd03
Compilation errors.
mll Mar 10, 2026
f8445f8
Static call improvements.
mll Mar 10, 2026
d7a9f16
WIP
mll Mar 11, 2026
2af741d
WIP
mll Mar 11, 2026
f200006
WIP exceptions
mll Mar 11, 2026
68a7b09
Make frames continous.
mll Mar 11, 2026
beb5a76
Symbolication
mll Mar 11, 2026
bd6d6e8
Bring back classes for tests.
mll Mar 11, 2026
80ddc9b
Add exception testing in runtime.
mll Mar 11, 2026
b2334b4
Integer tests.
mll Mar 11, 2026
09e4a8d
Vector exceptions.
mll Mar 11, 2026
1f70317
PersistentArrayMap
mll Mar 11, 2026
126854b
String
mll Mar 11, 2026
ea340ad
Exceptions for hash map.
mll Mar 11, 2026
37e4853
Improve filename reporting
mll Mar 11, 2026
9cd3482
Improve divisions.
mll Mar 11, 2026
5b7c793
Integer overflow.
mll Mar 11, 2026
1809a19
Readable types
mll Mar 11, 2026
7de042c
Skip generic impl in static case.
mll Mar 11, 2026
ef0e0ae
Remove unneeded tests.
mll Mar 11, 2026
87366af
If node.
mll Mar 11, 2026
d1cfbb3
Static call type folding.
mll Mar 11, 2026
a9d6cd6
Cleanup
mll Mar 11, 2026
2421f68
Constant folding in arithmetic.
mll Mar 11, 2026
89724ac
Refactor
mll Mar 11, 2026
108276d
segfault fix.
mll Mar 11, 2026
9dea5dc
Add IfNode
mll Mar 11, 2026
da87209
Complete BigInteger support.
mll Mar 11, 2026
f4b802d
Remove an awkward include
mll Mar 11, 2026
f6866fb
Compile on linux
mll Mar 11, 2026
7107727
Mem leaks
mll Mar 11, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,9 @@ backend-v2/Testing*
backend-v2/build_cov/*
backend-v2/libbackend_lib.a
backend-v2/.cache*
backend-v2/compile_commands.json
backend-v2/clojure-rt.dSYM
backend-v2/CMakeUserPresets.json


/.clj-kondo/babashka
Expand Down
23 changes: 15 additions & 8 deletions backend-v2/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,14 @@
cmake_minimum_required(VERSION 3.26)
project(clojure-rt)
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)


if(APPLE)
if(NOT CMAKE_OSX_ARCHITECTURES)
set(CMAKE_OSX_ARCHITECTURES "arm64")
endif()
set(CMAKE_XCODE_ATTRIBUTE_DEBUG_INFORMATION_FORMAT "dwarf-with-dsym")
endif()


message(STATUS "CMAKE_OSX_ARCHITECTURES: ${CMAKE_OSX_ARCHITECTURES}")
Expand All @@ -22,13 +31,6 @@ set(CMAKE_CXX_FLAGS_RELEASE "-Ofast")
set(CMAKE_CXX_STANDARD 20)
add_compile_definitions(BUILD_TYPE="${CMAKE_BUILD_TYPE}")

if(APPLE)
if(NOT CMAKE_OSX_ARCHITECTURES)
set(CMAKE_OSX_ARCHITECTURES "arm64")
endif()
set(CMAKE_XCODE_ATTRIBUTE_DEBUG_INFORMATION_FORMAT "dwarf-with-dsym")
endif()

add_subdirectory(runtime)

# --- Dependency Discovery ---
Expand Down Expand Up @@ -117,11 +119,16 @@ set(BACKEND_SOURCES
codegen/LLVMTypes.cpp
codegen/DynamicConstructor.cpp
codegen/invoke/InvokeManager.cpp
codegen/invoke/InvokeManager_Math.cpp
codegen/invoke/InvokeManager_Cmp.cpp

codegen/MemoryManagement.cpp
codegen/ops/ConstNode.cpp
codegen/ops/QuoteNode.cpp
codegen/ops/VectorNode.cpp
codegen/ops/MapNode.cpp)
codegen/ops/MapNode.cpp
codegen/ops/StaticCallNode.cpp
codegen/ops/IfNode.cpp)


# 2. Protobuf Detection
Expand Down
30 changes: 17 additions & 13 deletions backend-v2/RuntimeHeaders.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,8 @@

#include <gmp.h>

#ifdef __cplusplus
#include <atomic>
#include <memory>
extern "C" {
#endif
#ifdef __cplusplus
// For C++ to understand C's 'restrict' keyword
#if defined(__cplusplus)
#if defined(__GNUC__) || defined(__clang__)
#define restrict __restrict__
#elif defined(_MSC_VER)
Expand All @@ -18,21 +14,29 @@ extern "C" {
#endif
#endif

#include "runtime/ObjectProto.h"
#include "runtime/RTValue.h"
#include "runtime/defines.h"
#include "runtime/word.h"

#include "runtime/BigInteger.h"
#include "runtime/Boolean.h"
#include "runtime/Class.h"
#include "runtime/ConcurrentHashMap.h"
#include "runtime/Double.h"
#include "runtime/Function.h"
#include "runtime/Integer.h"
#include "runtime/Keyword.h"
#include "runtime/Nil.h"
#include "runtime/Object.h"
#include "runtime/ObjectProto.h"
#include "runtime/PersistentArrayMap.h"
#include "runtime/PersistentList.h"
#include "runtime/PersistentVector.h"
#include "runtime/RTValue.h"
#include "runtime/PersistentVectorIterator.h"
#include "runtime/PersistentVectorNode.h"
#include "runtime/Ratio.h"
#include "runtime/RuntimeInterface.h"
#include "runtime/String.h"
#include "runtime/Symbol.h"
#include "runtime/defines.h"
#include "runtime/word.h"

#ifdef __cplusplus
}
#endif
#endif
Loading
Loading