Commit graph

209 commits

Author SHA1 Message Date
Noah
a0790d4906 Use ahash in the compiler 2021-01-08 17:00:23 -06:00
Noah
64fa9ccba9 Don't push something on the stack when starting a generator 2020-12-23 17:40:33 -06:00
Noah
a2c0db23f6 Don't keep a separate blockorder vec 2020-12-21 18:49:00 -06:00
Noah
d567f967e8 Use boxvec for frame.stack 2020-12-21 18:48:56 -06:00
Noah
596e338c51 Have a block-based IR for compiling, calculate max stack size 2020-12-21 18:47:58 -06:00
Noah
db041c0f6c Update other stuff to use the root of rustpython_bytecode 2020-12-19 14:59:07 -06:00
Noah
b9875ff9bf Make Instruction only 8 bytes 2020-12-14 15:55:47 -06:00
Noah
1575382577 Add flags to the MakeFunction instruction 2020-12-14 14:35:17 -06:00
Noah
86aa00c473 Add label_arg{,_mut} methods 2020-12-14 14:25:20 -06:00
Noah
74a917a72e Make Continue have the target it's continuing to 2020-12-14 14:25:19 -06:00
Noah
48ca658ba0 Optimize the size of Instruction 2020-12-14 14:25:19 -06:00
Noah
281e955663 Import ConstantData in compile.rs 2020-12-14 14:25:19 -06:00
Noah
ff8512cd54 Apply review suggestions 2020-12-05 16:36:38 -06:00
Noah
9305316f69 Use a boxed slice for codeobject fields 2020-12-05 16:36:37 -06:00
Noah
8458e13e35 Fast locals part 3 2020-12-05 16:36:35 -06:00
Noah
e18275566a Fast locals part 2 2020-12-05 16:36:00 -06:00
Noah
410bd76f38 Fast locals part 1 2020-12-05 16:36:00 -06:00
Noah
534ca2a8de Move compiler snapshots 2020-12-05 16:36:00 -06:00
Noah
df41efed8a Don't use a wildcard to prevent future mistakes 2020-11-24 11:57:14 -06:00
Noah
38c4c14ee3 Remove the need for a label_map in CodeObject 2020-11-23 14:41:56 -06:00
Noah
e37a55e74c Implement string interning for variable names 2020-11-09 15:51:57 -06:00
Noah
31b884d37a compiler/porcelain wrapper 2020-11-07 15:43:23 -06:00
Noah
e9095a741d Split the ast from the parser, remove compiler dep on parser 2020-11-07 15:43:23 -06:00
Noah
3f88b08aaa Capitalize boolean constants for dis 2020-10-30 14:05:53 -05:00
Noah
4afbc082ed Use disassembly for snapshot testing 2020-10-19 23:55:56 -05:00
Noah
3f9dd3dd4c Remove optimization unit test 2020-10-19 23:55:56 -05:00
Noah
868fdfcc36 Fix clippy lints 2020-10-19 23:55:55 -05:00
Noah
ebee651a12 Update compiler to output codeobj.constants, use insta for snapshot testing 2020-10-19 23:55:55 -05:00
Tom Schuster
6d0978226e Basic block support in JIT 2020-10-17 17:42:02 +02:00
Noah
eedbf3aa6c Fix __class__ nonlocal resolution 2020-10-07 19:33:11 -05:00
Noah
16a896d513 Fix accessing __doc__ while inside a class definition 2020-10-07 19:28:19 -05:00
Jeong YunWon
09b8414162 Fix nightly clippy 2020-10-01 07:08:55 +09:00
Jeong YunWon
6c96793f05 Fix dis.dis to prints inner constant codes like CPython 2020-09-21 06:09:55 +09:00
minoring
09e4e9a86c Refactor checks for symbol in register_name 2020-09-06 11:40:32 +09:00
minoring
678b8e779b Modify nonlocal to be declared multiple times
Related to #2183
2020-09-05 22:42:52 +09:00
minoring
de7396347f Fix nonlocal checks
Related to #2189
2020-09-05 22:41:24 +09:00
Noah
a251109090 Fix some minor things required for unittest 2020-08-20 04:18:21 +09:00
Jeong YunWon
f9fe1c0423 Revert "Merge pull request #2106 from RustPython/coolreader18/unittest-tests"
This reverts commit 96926daf6ffa2a8dbb374b3c6169b378bd0d67ef, reversing
changes made to 230f91582f98ff74abeb8759718e49c386e2b398.
2020-08-20 04:18:21 +09:00
Noah
7f0798b235 Fix some minor things required for unittest 2020-08-12 16:03:20 -05:00
Yiqun Ling
d8c8b11726 Add nested and optimized for symtable 2020-08-13 04:12:28 +09:00
Noah
3c080eb4cc Merge pull request #2006 from Lynskylate/try-to-use-local
Use loadname local replace loadname free
2020-08-11 10:13:35 -05:00
Jeong YunWon
7714871b37 clean up PyComplex 2020-08-09 21:46:16 +09:00
lynskylate
2b54fa871f Fix load context 2020-08-08 13:08:13 +08:00
lynskylate
f6eb1168bc Fix scope error 2020-08-08 01:53:13 +08:00
lynskylate
a6be7eea26 Merge remote-tracking branch 'origin/master' into try-to-use-local 2020-08-07 01:18:56 +08:00
lynskylate
32232811fb Fix scope change 2020-08-02 03:43:19 +08:00
lynskylate
dcca662432 Optimize code 2020-08-01 02:05:44 +08:00
Yiqun Ling
70eeb28748 Apply suggestions from code review
Co-authored-by: Jeong YunWon <youknowone@users.noreply.github.com>
2020-08-01 01:29:11 +08:00
lynskylate
6a66f88304 Merge remote-tracking branch 'origin/master' into feature-symtable 2020-07-31 02:12:41 +08:00
lynskylate
66731121ab Introduce symtable test and add is_annotation for symbol 2020-07-31 02:11:00 +08:00