(c) 2022 YSI contibutors, licensed under MPL 1.1
CTRL_OnCodeInit()
Initialise the system
CodeScanAddMatcher
CodeScanInit
CodeScanMatcher
CodeScanMatcherInit_
CodeScanMatcherPattern_
CodeScanRunFast
CodeScanner
Functional_FoundCall1
Functional_FoundCall2
LAM@0
O@A_
O@V_
OP_CALL
OP_CONST_PRI
OP_PUSH_C
OP_PUSH_PRI
OP_ZERO_PRI
__1_cell
gCodeScanCallback_match
public
713 cells
Functional_FoundAfter(scanner[])
Name | Info |
---|---|
scanner |
[172] The code scanner that found a match. |
Called when a scanner matches a LAM@5()
call, denoting the end of the lambda call. Just removes the call and stores the location.
CodeScanGetMatchAddressData
CodeScanNOPMatch
YSI_g_sFunctionalAfterPos
YSI_g_sFunctionalLastEnd
cellmin
4 cells
Functional_FoundCall(scanner[], nestingLevel)
Name | Info |
---|---|
scanner |
[172] The code scanner that found a match. |
nestingLevel |
How many lambdas deep this call is. |
Once a lambda call is found this code is called to trigger a new set of scans to analyse the lambda function itself. It then does the code generation based on the results. This is to allow nested lambdas as the calls are found first, then the second set of scans run without preventing the call scanner from finding more results later.
AsmContext
AsmEmitAddC
AsmEmitHeap
AsmEmitJumpRel
AsmEmitLctrl
AsmEmitLoadPri
AsmEmitMovs
AsmEmitSctrl
AsmEmitStack
AsmEmitStorPri
AsmInitPtr
CodeScanAddMatcher
CodeScanClone
CodeScanGetMatchAddressData
CodeScanGetMatchStack
CodeScanMatcher
CodeScanMatcherInit_
CodeScanMatcherPattern_
CodeScanNOPMatch
CodeScanRun
CodeScanner
Functional_FoundAfter
Functional_FoundEnd
Functional_FoundStart
I@
LAM@1
LAM@2
LAM@5
O@A_
O@V_
OP_CALL
OP_CONST_PRI
OP_PUSH_C
OP_PUSH_PRI
OP_ZERO_PRI
YSI_g_sFunctionalAfterPos
YSI_g_sFunctionalEndPos
YSI_g_sFunctionalExpectedDepth
YSI_g_sFunctionalLastEnd
YSI_g_sFunctionalStartPos
__10_cells
__12_cells
__14_cells
__1_cell
__2_cells
__4_cells
__5_cells
__8_cells
__hea
__stk
gCodeScanCallback_match
1488 cells
Functional_FoundCall1(scanner[])
Name | Info |
---|---|
scanner |
[172] The code scanner that found a match. |
Used when a matcher finds a lambda call with an explicit nesting level.
6 cells
Functional_FoundCall2(scanner[])
Name | Info |
---|---|
scanner |
[172] The code scanner that found a match. |
Used when a matcher finds a lambda call with a ZERO op for the nesting level.
5 cells
Functional_FoundEnd(scanner[])
Name | Info |
---|---|
scanner |
[172] The code scanner that found a match. |
Called when a scanner matches a LAM@2()
call, denoting the end of a lambda function. Just removes the call and stores the location.
4 cells
Functional_FoundStart(scanner[])
Name | Info |
---|---|
scanner |
[172] The code scanner that found a match. |
Called when a scanner matches a LAM@1()
call, denoting the start of a lambda function. Just removes the call and stores the location.
CodeScanGetMatchAddressData
CodeScanGetMatchStack
CodeScanNOPMatch
YSI_g_sFunctionalExpectedDepth
YSI_g_sFunctionalStartPos
4 cells
LAM@0(idx)
Name | Info |
---|---|
idx |
Used by nested lambda calls. |
Marks the point in code where the lambda function gets called.
1 cells
LAM@1(idx, pattern0, pattern1, pattern2, pattern3)
Name | Info |
---|---|
idx |
|
pattern0 |
|
pattern1 |
|
pattern2 |
|
pattern3 |
Placeholder function used to deonte the start of lambda code. All parameters are dummies, used for code scanning and generation space padding.
1 cells
LAM@2(par)
Name | Info |
---|---|
par |
Placeholder function used to deonte the end of lambda code. The parameter is eventually used in the rewitten code to return the result.
1 cells
LAM@5(idx, pattern0, pattern1, pattern2, pattern3, pattern4, pattern5, pattern6)
Name | Info |
---|---|
idx |
|
pattern0 |
|
pattern1 |
|
pattern2 |
|
pattern3 |
|
pattern4 |
|
pattern5 |
|
pattern6 |
The end of all the generated code; functions and calls.
1 cells