forked from ianh/owl
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Allocate the reachability_mask bitset to the correct size.
The reachability_mask_width function computes the number of 32-bit integers needed to represent the reachability mask in the generated parser. But the actual bitset in the generator needs enough bits for every transition. Since the bitset is allocated in 64-bit chunks, things only start to go wrong when there are more than 64 distinct bracket transition symbols. Add a test case (generated by https://github.com/Luctia/owl_perftest) that has enough nesting to generate this many bracket transitions. Thanks to Luc Timmerman for finding this bug.
- Loading branch information
Showing
6 changed files
with
78 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
---nested71 = [ '(' nested70 ')' ] | ||
nested70 = [ '(' nested69 ')' ] | ||
nested69 = [ '(' nested68 ')' ] | ||
nested68 = [ '[' nested67 ']' ] | ||
nested67 = [ '{' nested66 '}' ] | ||
nested66 = [ '(' nested65 ')' ] | ||
nested65 = [ '[' nested64 ']' ] | ||
nested64 = [ '[' nested63 ']' ] | ||
nested63 = [ '[' nested62 ']' ] | ||
nested62 = [ '[' nested61 ']' ] | ||
nested61 = [ '(' nested60 ')' ] | ||
nested60 = [ '{' nested59 '}' ] | ||
nested59 = [ '{' nested58 '}' ] | ||
nested58 = [ '(' nested57 ')' ] | ||
nested57 = [ '[' nested56 ']' ] | ||
nested56 = [ '{' nested55 '}' ] | ||
nested55 = [ '[' nested54 ']' ] | ||
nested54 = [ '(' nested53 ')' ] | ||
nested53 = [ '{' nested52 '}' ] | ||
nested52 = [ '{' nested51 '}' ] | ||
nested51 = [ '[' nested50 ']' ] | ||
nested50 = [ '[' nested49 ']' ] | ||
nested49 = [ '(' nested48 ')' ] | ||
nested48 = [ '[' nested47 ']' ] | ||
nested47 = [ '(' nested46 ')' ] | ||
nested46 = [ '[' nested45 ']' ] | ||
nested45 = [ '[' nested44 ']' ] | ||
nested44 = [ '{' nested43 '}' ] | ||
nested43 = [ '[' nested42 ']' ] | ||
nested42 = [ '[' nested41 ']' ] | ||
nested41 = [ '[' nested40 ']' ] | ||
nested40 = [ '{' nested39 '}' ] | ||
nested39 = [ '[' nested38 ']' ] | ||
nested38 = [ '[' nested37 ']' ] | ||
nested37 = [ '{' nested36 '}' ] | ||
nested36 = [ '{' nested35 '}' ] | ||
nested35 = [ '{' nested34 '}' ] | ||
nested34 = [ '(' nested33 ')' ] | ||
nested33 = [ '(' nested32 ')' ] | ||
nested32 = [ '{' nested31 '}' ] | ||
nested31 = [ '(' nested30 ')' ] | ||
nested30 = [ '[' nested29 ']' ] | ||
nested29 = [ '[' nested28 ']' ] | ||
nested28 = [ '[' nested27 ']' ] | ||
nested27 = [ '[' nested26 ']' ] | ||
nested26 = [ '[' nested25 ']' ] | ||
nested25 = [ '(' nested24 ')' ] | ||
nested24 = [ '[' nested23 ']' ] | ||
nested23 = [ '[' nested22 ']' ] | ||
nested22 = [ '[' nested21 ']' ] | ||
nested21 = [ '[' nested20 ']' ] | ||
nested20 = [ '[' nested19 ']' ] | ||
nested19 = [ '[' nested18 ']' ] | ||
nested18 = [ '[' nested17 ']' ] | ||
nested17 = [ '{' nested16 '}' ] | ||
nested16 = [ '(' nested15 ')' ] | ||
nested15 = [ '(' nested14 ')' ] | ||
nested14 = [ '{' nested13 '}' ] | ||
nested13 = [ '[' nested12 ']' ] | ||
nested12 = [ '[' nested11 ']' ] | ||
nested11 = [ '{' nested10 '}' ] | ||
nested10 = [ '(' nested9 ')' ] | ||
nested9 = [ '(' nested8 ')' ] | ||
nested8 = [ '(' nested7 ')' ] | ||
nested7 = [ '[' nested6 ']' ] | ||
nested6 = [ '{' nested5 '}' ] | ||
nested5 = [ '[' nested4 ']' ] | ||
nested4 = [ '[' nested3 ']' ] | ||
nested3 = [ '[' nested2 ']' ] | ||
nested2 = [ '(' nested1 ')' ] | ||
nested1 = [ '(' nested0 ')' ] | ||
nested0 = string | number |
2 changes: 2 additions & 0 deletions
2
test/results/nested-reachability-mask-crash.owltest.cc-stderr
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
parse error: more input needed | ||
error: 'test executable' exited with status 255 |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
error: expected more text after the last token | ||
|
||
|
Empty file.