Skip to content

Commit 81e5d88

Browse files
review work
1 parent 3758187 commit 81e5d88

9 files changed

Lines changed: 21 additions & 112 deletions

File tree

src/views/component-viewer/model/scvd-format-specifier.ts

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -19,16 +19,6 @@ import { NumberType, NumFormat } from './number-type';
1919
// https://arm-software.github.io/CMSIS-View/main/elem_component_viewer.html
2020

2121

22-
/* Note:
23-
Question 1 (HEX display of float):
24-
What should be the expected behavior for displaying float32 and float64 values in hexadecimal format? Should they be shown as truncated unsigned integers (UINT) or in their raw IEEE representation?
25-
A: show as truncated integers
26-
27-
Question 2 (0x000... padding):
28-
What should be the maximum padding size for HEX zeros (0x000...<num>): 32 or 64?
29-
A: show the value without padding zeros, i.e. 0x3, 0x3bc4
30-
*/
31-
3222
export type FormatKind = 'int' | 'uint' | 'float' | 'unknown';
3323
export interface FormatTypeInfo {
3424
kind: FormatKind;

src/views/component-viewer/model/scvd-item.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ export class ScvdItem extends ScvdNode {
3636

3737
constructor(
3838
parent: ScvdNode | undefined,
39-
cond?: string, // = '1',
40-
bold?: string, // = '0',
41-
alert?: string, // = '0',
39+
cond?: string,
40+
bold?: string,
41+
alert?: string,
4242
) {
4343
super(parent);
4444
if (cond !== undefined) {

src/views/component-viewer/model/scvd-register-access.ts

Lines changed: 0 additions & 33 deletions
This file was deleted.

src/views/component-viewer/model/scvd-typedef.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -75,15 +75,16 @@ export class ScvdTypedefs extends ScvdNode {
7575
}
7676

7777
/*
78-
import:
78+
Member-import (Attribute import="symbol-name" from SCVD xml):
7979
Name of a symbol in the user application which is loaded into the debugger.
80-
The underlaying data type of this symbol is used to:
81-
80+
The underlaying data type of this symbol is used to
8281
recalculate the value of the attribute size of this typedef element.
83-
for member elements with no explicit attribute offset, the offset value of
82+
For member elements with no explicit attribute offset, the offset value of
8483
matching member is set. If the member is not part of the symbol in the user
8584
application the attribute offset value is set to -1.
8685
__Offset_of can be used to check this value.
86+
87+
Currently this is not supported due to MS-DAP restrictions.
8788
*/
8889

8990
export class ScvdTypedef extends ScvdNode {

src/views/component-viewer/parser-evaluator/parser.ts

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -13,22 +13,8 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16-
// generated with AI
1716

18-
/**
19-
* Fast, reusable, error-tolerant expression parser with:
20-
* - Assignment '=' (right-associative) and C-style compound assignments: +=, -=, *=, /=, %=, <<=, >>=, &=, ^=, |=
21-
* - ++ / -- (both prefix and postfix)
22-
* - Printf-like formatting segments: `%x[ expr ]` (x = ANY single non-space char) and `%%` (escaped percent)
23-
* - Intrinsic evaluation-point calls:
24-
* __CalcMemUsed, __FindSymbol, __GetRegVal, __Offset_of, __size_of, __Symbol_exists, __Running
25-
* - Constant folding (never folds assignments; side-effecting nodes are kept as AST)
26-
* - External symbol collection
27-
* - Colon selector operators `typedef_name:member` and `typedef_name:member:enum`
28-
* - Ternary conditional `?:` (right-associative)
29-
*
30-
* Intended to be instantiated once and reused: `const parser = new Parser();`
31-
*/
17+
// generated with AI
3218

3319
import { addVals, andVals, divVals, maskToBits, modVals, mulVals, orVals, sarVals, shlVals, subVals, toNumeric, xorVals } from './math-ops';
3420
import { INTRINSIC_DEFINITIONS, isIntrinsicName } from './intrinsics';

src/views/component-viewer/statement-engine/statement-list-out.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,11 @@ export class StatementListOut extends StatementBase {
3535
}
3636

3737
await this.onExecute(executionContext, guiTree);
38-
/*for (const child of this.children) { // executed in list
38+
/* Example code for evaluating children.
39+
Normally this happens here, but in this case it’s done in onExecute
40+
to account for the loop and its variables.
41+
42+
for (const child of this.children) { // executed in list
3943
await child.executeStatement(executionContext, guiTree);
4044
}*/
4145
}

src/views/component-viewer/statement-engine/statement-list.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,11 @@ export class StatementList extends StatementBase {
3535
}
3636

3737
await this.onExecute(executionContext, guiTree);
38-
/*for (const child of this.children) { // executed in list
38+
/* Example code for evaluating children.
39+
Normally this happens here, but in this case it’s done in onExecute
40+
to account for the loop and its variables.
41+
42+
for (const child of this.children) { // executed in list
3943
await child.executeStatement(executionContext, guiTree);
4044
}*/
4145
}

src/views/component-viewer/statement-engine/statement-out.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@
1414
* limitations under the License.
1515
*/
1616

17+
// generated with AI
18+
1719
import { ScvdNode } from '../model/scvd-node';
1820
import { ExecutionContext } from '../scvd-eval-context';
1921
import { ScvdGuiTree } from '../scvd-gui-tree';

src/views/component-viewer/test/unit/model/scvd-register-access.test.ts

Lines changed: 0 additions & 45 deletions
This file was deleted.

0 commit comments

Comments
 (0)