Commit Graph

  • c2005a5f79 tgo: Add rudimentary interface support. Ayke van Laethem 2018-06-07 15:48:32 +02:00
  • 0168bf7797 Add goroutines and function pointers Ayke van Laethem 2018-06-07 14:48:24 +02:00
  • 8df220a53b Move to my own fork of LLVM Ayke van Laethem 2018-06-07 13:20:09 +02:00
  • 1eccae287b tgo: Fix runtime.TargetBits Ayke van Laethem 2018-06-04 01:09:33 +02:00
  • d1dbca53ff tgo: Eliminate most debug prints Ayke van Laethem 2018-06-03 23:50:14 +02:00
  • 315e39b164 tgo: Remove getGlobalName from Compiler object Ayke van Laethem 2018-06-03 23:37:15 +02:00
  • b4e60deacd runtime/nrf: Fix allocator by adding align() function Ayke van Laethem 2018-06-03 17:56:56 +02:00
  • 2390b24c5a tgo: Add extra chip types for nRF Ayke van Laethem 2018-06-03 17:54:18 +02:00
  • 5fa39adb81 tgo: Allow anonymous function declarations Ayke van Laethem 2018-06-03 17:45:33 +02:00
  • 588910792d Translate bootstrapping main from C to LLVM IR Ayke van Laethem 2018-06-03 17:32:10 +02:00
  • a9bbed2f6c tgo: Implement special case for LLVM intrinsics Ayke van Laethem 2018-06-03 17:13:00 +02:00
  • 89f77fa861 machine/dummy: Add LED1, LED2, etc to dummy machine Ayke van Laethem 2018-06-03 16:42:09 +02:00
  • 320c583221 Implement printing of int8/uint8/pointers Ayke van Laethem 2018-06-03 16:39:24 +02:00
  • e171f32493 Implement minimal bump pointer allocator Ayke van Laethem 2018-06-03 16:18:40 +02:00
  • b45ea2deb9 arm: Fix linker script stack section Ayke van Laethem 2018-05-28 10:55:14 +02:00
  • 2fca772431 Makefile: Autodetect LLVM bin dir Ayke van Laethem 2018-05-28 09:00:12 +02:00
  • a39951c3d7 runtime: Convert device initialization to Go Ayke van Laethem 2018-05-05 20:08:17 +02:00
  • c4f0dc90dd machine: Rewrite most of the GPIO functionality Ayke van Laethem 2018-05-05 20:02:00 +02:00
  • 16489c0df6 compiler: Workaround for runtime.boundsCheck in runtime dependencies Ayke van Laethem 2018-05-05 19:18:53 +02:00
  • 01602309fd compiler: Implement register loads and stores Ayke van Laethem 2018-05-05 19:17:23 +02:00
  • 8c426b406d Automatically convert .svd files to Go source files Ayke van Laethem 2018-05-05 19:02:43 +02:00
  • 3b4621c215 compiler: Implement XOR (^x) Ayke van Laethem 2018-05-05 18:33:32 +02:00
  • 877d0817ea compiler: Comments Ayke van Laethem 2018-05-05 18:32:58 +02:00
  • 84b45a33f1 compiler: Implement initializers for arrays in global structs Ayke van Laethem 2018-05-05 18:30:58 +02:00
  • db8b6c6900 compiler: Fix package dependency order calculation Ayke van Laethem 2018-05-05 18:29:23 +02:00
  • 88f143f3e6 compiler: Implement initializers for global structs Ayke van Laethem 2018-05-03 22:38:04 +02:00
  • b0cb51bdd8 compiler: Do not pre-define runtime functions by the compiler Ayke van Laethem 2018-05-03 21:15:29 +02:00
  • b11a618d99 compiler: Set actual initializer for global variables Ayke van Laethem 2018-04-29 00:57:50 +02:00
  • c5a82bb916 compiler: Fix globals so they actually work Ayke van Laethem 2018-04-29 00:49:33 +02:00
  • 14cbc1555d compiler: Use zeroinitializer instead of memset Ayke van Laethem 2018-04-29 00:48:42 +02:00
  • 6ed1ca11c7 compiler: Use correct package path for global Ayke van Laethem 2018-04-29 00:47:26 +02:00
  • 2534111141 compiler: comments Ayke van Laethem 2018-04-27 16:19:57 +02:00
  • e895372918 compiler: Don't externally link runtime.init Ayke van Laethem 2018-04-27 16:19:29 +02:00
  • 3a4663150e runtime: Implement GPIO output Ayke van Laethem 2018-04-27 01:29:13 +02:00
  • 5bbd41e9fb compiler: Implement -ffunction-sections work Ayke van Laethem 2018-04-27 01:27:33 +02:00
  • f7c2d0124d compiler: Support bitcasting non-integers Ayke van Laethem 2018-04-27 00:59:27 +02:00
  • bddb0c49b2 compiler: Add boolean constants Ayke van Laethem 2018-04-27 00:59:01 +02:00
  • 6ad451a582 compiler: Fix named global path Ayke van Laethem 2018-04-27 00:58:28 +02:00
  • 4522d2f49e Makefile: Remove SECONDARY: rule Ayke van Laethem 2018-04-26 23:50:01 +02:00
  • d4170faa0a runtime/nrf: Add Sleep() Ayke van Laethem 2018-04-26 23:47:59 +02:00
  • 4491a63fe8 Add print() for 64-bit integers Ayke van Laethem 2018-04-26 23:46:34 +02:00
  • d17c21681b compiler: Accept more variable types in print() Ayke van Laethem 2018-04-26 23:41:20 +02:00
  • d13566b302 compiler: Don't ignore errors in parsePackage Ayke van Laethem 2018-04-26 23:40:19 +02:00
  • f4ee774866 Set up a stack Ayke van Laethem 2018-04-26 23:38:46 +02:00
  • c940617849 compiler: Implement init() Ayke van Laethem 2018-04-26 18:54:46 +02:00
  • 9a988dd1d1 compiler: Refactor Compiler.Parse: extract parsePackage Ayke van Laethem 2018-04-26 18:52:57 +02:00
  • 2d19bb11ba compiler: Merge the runtime into the Go code, for better code size Ayke van Laethem 2018-04-26 18:06:54 +02:00
  • 775445cceb compiler: Reduce code size Ayke van Laethem 2018-04-26 17:16:54 +02:00
  • a446b4de97 Be able to actually run the blinky example on an nRF Ayke van Laethem 2018-04-25 20:09:42 +02:00
  • 10427c2b6f Add blinky example (which doesn't blink a LED, yet) Ayke van Laethem 2018-04-25 20:07:04 +02:00
  • 04fef19753 Add runtime support for the nRF52 Ayke van Laethem 2018-04-25 20:06:08 +02:00
  • e80f06bc5e Implement more type casting Ayke van Laethem 2018-04-25 19:50:46 +02:00
  • 69140c240b Implement named binop types Ayke van Laethem 2018-04-25 19:49:54 +02:00
  • b4ba90d7f5 Implement uintptr type Ayke van Laethem 2018-04-25 19:48:42 +02:00
  • 51b947956f Use Clang as CGo compiler Ayke van Laethem 2018-04-25 19:46:54 +02:00
  • 93399c009e Emit textual LLVM IR Ayke van Laethem 2018-04-25 19:46:03 +02:00
  • ea129f3072 Implement runtime.Sleep Ayke van Laethem 2018-04-22 19:23:16 +02:00
  • cefce41df0 Correct function name for calls to other packages Ayke van Laethem 2018-04-22 19:22:12 +02:00
  • 9d3dfd8868 Make package process order deterministic: based on import order Ayke van Laethem 2018-04-22 19:06:44 +02:00
  • 03c6b7256e Simplify parseConstInt Ayke van Laethem 2018-04-22 15:59:45 +02:00
  • 5067891236 Implement unsigned integers Ayke van Laethem 2018-04-22 15:59:17 +02:00
  • 75fce0f949 runtime: Move print functions to separate file Ayke van Laethem 2018-04-22 15:26:07 +02:00
  • cf9cea7a0d Implement array bounds check Ayke van Laethem 2018-04-21 01:03:05 +02:00
  • 1f0651c84c Implement string out of bounds checks Ayke van Laethem 2018-04-21 00:26:45 +02:00
  • db66039dfe Implement panic() Ayke van Laethem 2018-04-20 23:59:55 +02:00
  • d812873e60 Add support for (zero-initialized) arrays Ayke van Laethem 2018-04-20 23:57:27 +02:00
  • 02332080e6 Use LLVM API for type size calculations Ayke van Laethem 2018-04-20 23:55:30 +02:00
  • 217c48f933 Implement interfaces on the string type Ayke van Laethem 2018-04-20 22:42:43 +02:00
  • fc2eee4ee8 Better error checking on interface conversion Ayke van Laethem 2018-04-20 17:22:20 +02:00
  • 12eb9eec3c Store LLVM reference instead of function name in Frame Ayke van Laethem 2018-04-20 17:04:06 +02:00
  • 45e7376f39 Implement print() and println() in Go Ayke van Laethem 2018-04-20 16:32:40 +02:00
  • ff9e7a8b77 Implement CGo support Ayke van Laethem 2018-04-20 16:22:39 +02:00
  • deadcb8dae Implement lookup on strings (extract byte values) Ayke van Laethem 2018-04-20 16:20:13 +02:00
  • 4d33d9d38b Implement -expr Ayke van Laethem 2018-04-20 16:18:54 +02:00
  • 01d2cc566e Fix type width for pointer types Ayke van Laethem 2018-04-20 16:18:09 +02:00
  • e436ca7c8d Implement named constants Ayke van Laethem 2018-04-20 14:52:07 +02:00
  • f5f64782ce Add casting between types Ayke van Laethem 2018-04-20 14:50:52 +02:00
  • 3e3c3d259f Add rudimentary interface support Ayke van Laethem 2018-04-19 20:30:06 +02:00
  • 850fef9852 Add builtin len(string) Ayke van Laethem 2018-04-19 20:23:48 +02:00
  • 013b375904 Add type methods Ayke van Laethem 2018-04-16 17:04:49 +02:00
  • 139ac45cb1 Use only putchar() for printing Ayke van Laethem 2018-04-16 01:56:10 +02:00
  • 9060e699e4 Add heap allocation (without escape analysis!) Ayke van Laethem 2018-04-16 01:55:44 +02:00
  • d555ad93d7 Add support for structs Ayke van Laethem 2018-04-16 01:01:11 +02:00
  • de0ff3b3af Various changes Ayke van Laethem 2018-04-15 04:49:00 +02:00
  • 5dfcb5f085 Reorganize packages Ayke van Laethem 2018-04-15 03:38:01 +02:00
  • 60a01a43a3 Implement strings the way Go itself does Ayke van Laethem 2018-04-14 19:24:21 +02:00
  • 7cc2301621 Print LLVM IR on verify failure Ayke van Laethem 2018-04-14 19:09:19 +02:00
  • 63a545540d Add Jump and Phi support, to enable things like for loops Ayke van Laethem 2018-04-14 19:07:29 +02:00
  • ad98a29a6f Add first branching support (if) Ayke van Laethem 2018-04-13 22:18:22 +02:00
  • fdf907c96c Add some more binops Ayke van Laethem 2018-04-13 22:17:49 +02:00
  • cc5a29d759 Add a load of binops Ayke van Laethem 2018-04-13 21:03:35 +02:00
  • 6607cff14e Print IR before optimization Ayke van Laethem 2018-04-13 20:30:45 +02:00
  • 01ee0c456c Handle local variables correctly Ayke van Laethem 2018-04-13 20:29:52 +02:00
  • e0e04b88cb Make expression statement more generic; introduce *Frame for func state Ayke van Laethem 2018-04-13 20:19:54 +02:00
  • 9d8d0b9e03 Treat llvm.Value as a pointer Ayke van Laethem 2018-04-13 20:03:35 +02:00
  • 30931ab3a6 Makefile cleanup Ayke van Laethem 2018-04-13 02:12:36 +02:00
  • 6a8dc7ca9a Support functions with parameters Ayke van Laethem 2018-04-13 02:11:12 +02:00
  • e0da91f753 Add return values Ayke van Laethem 2018-04-13 00:18:28 +02:00
  • 7be746e2f3 Make 'int' platform-dependent Ayke van Laethem 2018-04-13 00:14:16 +02:00
  • ea6ec58241 Fix function order - no random failures anymore! Ayke van Laethem 2018-04-12 23:21:47 +02:00