This is a project, for a Compiler Collection Framework and a Code Editor specifically for Java, C/Cpp and Python Projects. It gives you a build environment for creating and customizing codes and repositories.
| Module | Location | Purpose | Status |
|---|---|---|---|
| JavaCompiler | modules/javacompiler/ |
Modular Java-to-x86-64 NASM compiler pipeline (byte, short, char, int, long, float, double) |
Integrated & verified (184 tests; Windows & Linux NASM/GCC CI) |
| RKCC Studio | modules/studio/ |
Desktop IDE workspace application | Existing module preserved untouched |
| Boolean Prototype | modules/boolean/ |
Standalone boolean type module prototype | Existing module preserved untouched |
| Legacy Swing Editor | src/java/editor/ |
Early desktop editor entry point | Existing code preserved untouched |
- Source Provenance: Incrementally updated with full preserved Git history via
git subtree pull --prefix=modules/javacompilerfromKrishna2132/JavaCompiler(Integration PR#4-> Floating-Point PR#5, verifiedmaincommitabf2487). - Compiler Architecture:
Java Source -> Lexer -> ListTokenStream -> Parser (TypeRegistry / IntegralTypeParser / FloatingPointTypeParser) -> AstSemanticAdapter -> SemanticAnalyzer (TypedAst) -> X86AssemblyGenerator -> Linux x86-64 NASM ELF64 (sys_write/ld for integer-only; SSE/SSE2 + libc/libm for float/double). - Supported Language Subset:
byte,short,char(unsigned 16-bit),int,long, IEEE 754float(binary32), anddouble(binary64); declarations, assignments, unary+/-/~, explicit primitive numeric casts(byte)..(double), decimal/scientific/hex floating literals (0x1.0p3), binary+,-,*,/,%, integral bitwise/shifts (SEM003on float/double),MIN_VALUE / -1overflow guards, JLS 5.1.3 NaN/Inf cast saturation, and runtime__div_zerotraps. - Team Contributions:
- Krishna: Compiler core contracts (
AbstractTypeParser,TypeRegistry), lexer (including hex floats), token stream, diagnostics,NumericType/FloatingPointTypesystem,FloatingPointTypeParser, explicit casts, SSE/SSE2 backend (XmmRegisterAllocator,FloatingPointInstructionGenerator),CompilerPipeline,CompilerStageJsonExporter,CompilerCli, native toolchain/execution framework, and differential/randomized test harnesses. - Jatin: Parser and concrete AST nodes (
rkcc.compiler.parser,rkcc.compiler.ast). - Janesh: Integer type system (
IntegerType, promotions, range validation) andSemanticAnalyzer/SymbolTable(rkcc.compiler.types,rkcc.compiler.semantic). - Riya: Linux x86-64 NASM assembly generator (
rkcc.compiler.codegen). - Pending Integrations: Ayush's
Stringtype module and unifyingmodules/boolean/(Ankit) intoTypeRegistryremain future PRs.
- Krishna: Compiler core contracts (
# Build and run all 184 unit, differential, and randomized JVM tests (Windows or Linux)
mvn -B -f modules/javacompiler/pom.xml clean verify
# Run strict native ELF64 assembly + GNU ld / gcc -lm + native execution verification (Linux / WSL w/ nasm + binutils + gcc)
mvn -B -f modules/javacompiler/pom.xml clean verify -Drkcc.native.required=true
# Inspect compiler pipeline stages & generate x86-64 NASM assembly
java -cp modules/javacompiler/target/classes rkcc.compiler.integration.CompilerCli --input modules/javacompiler/examples/01_basic_arithmetic.java --tokens --ast --semantic --verbose
java -cp modules/javacompiler/target/classes rkcc.compiler.integration.CompilerCli --input modules/javacompiler/examples/07_basic_float_double.java --semantic
# Export structured JSON stage outputs (ready for future RKCC Studio / Neovim tooling integration)
java -cp modules/javacompiler/target/classes rkcc.compiler.integration.CompilerCli --input modules/javacompiler/examples/10_ieee754_special_values.java --json- Native Linux ELF64 assembly/linking/execution requires
nasm, GNUld(binutils), andgcc(libmfor floating-pointfmod/fmodf/printf); on Windows hosts without WSL/NASM/GCC, the 11 native execution tests skip cleanly viaNativeTestPreconditions. - Unsupported features:
String,booleanpipeline integration, arrays, control flow (if/while/for), methods, classes, MLIR/LLVM backends, and direct Neovim/RKCC Studio UI wiring (planned future milestones).