Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
H
hostCompiledSimulation
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Gaurav Kukreja
hostCompiledSimulation
Commits
7fbde717
Commit
7fbde717
authored
Sep 10, 2014
by
Gaurav Kukreja
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adding missed increment SP annotation at beginning of function
Signed-off-by:
Gaurav Kukreja
<
gaurav@gauravk.in
>
parent
5345bb3c
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
7 additions
and
1 deletion
+7
-1
cacheSimInstrument.py
instrument/cacheSimInstrument.py
+5
-1
adpcm_IR.c
instrument/examples/adpcm/instrumented/adpcm_IR.c
+1
-0
my_ctop_IR.c
instrument/examples/adpcm/instrumented/my_ctop_IR.c
+1
-0
No files found.
instrument/cacheSimInstrument.py
View file @
7fbde717
...
@@ -317,8 +317,12 @@ def annotateLoadStore(listISCFunctions, listObjdumpFunctions, listLSInfo, listGl
...
@@ -317,8 +317,12 @@ def annotateLoadStore(listISCFunctions, listObjdumpFunctions, listLSInfo, listGl
annot_str
=
"cacheSimInit();"
annot_str
=
"cacheSimInit();"
annot
=
Annotation
(
annot_str
,
funcISC
.
fileName
,
funcISC
.
cfg
.
listBlocks
[
0
]
.
startLine
-
1
,
False
)
annot
=
Annotation
(
annot_str
,
funcISC
.
fileName
,
funcISC
.
cfg
.
listBlocks
[
0
]
.
startLine
-
1
,
False
)
addAnnotationToDict
(
dictAnnotLoadStore
,
funcISC
.
cfg
.
listBlocks
[
0
]
.
startLine
-
1
,
annot
)
addAnnotationToDict
(
dictAnnotLoadStore
,
funcISC
.
cfg
.
listBlocks
[
0
]
.
startLine
-
1
,
annot
)
funcObj
=
find
(
lambda
fn
:
fn
.
functionName
==
funcISC
.
functionName
,
listObjdumpFunctions
)
funcObj
=
find
(
lambda
fn
:
fn
.
functionName
==
funcISC
.
functionName
,
listObjdumpFunctions
)
annot_str
=
"SP = SP + 0x
%
x;"
%
(
funcObj
.
stackSize
)
annot
=
Annotation
(
annot_str
,
funcISC
.
fileName
,
funcISC
.
cfg
.
listBlocks
[
0
]
.
startLine
-
1
,
False
)
addAnnotationToDict
(
dictAnnotLoadStore
,
funcISC
.
cfg
.
listBlocks
[
0
]
.
startLine
-
1
,
annot
)
for
blockObj
in
funcObj
.
cfg
.
listBlocks
:
for
blockObj
in
funcObj
.
cfg
.
listBlocks
:
mappedBlocksISCInd
=
blockObj
.
mapsTo
mappedBlocksISCInd
=
blockObj
.
mapsTo
blockLSInfo
=
findLoadStoreBetweenLines
(
listLSInfo
,
blockObj
.
startLine
,
blockObj
.
endLine
)
blockLSInfo
=
findLoadStoreBetweenLines
(
listLSInfo
,
blockObj
.
startLine
,
blockObj
.
endLine
)
...
...
instrument/examples/adpcm/instrumented/adpcm_IR.c
View file @
7fbde717
...
@@ -111,6 +111,7 @@ void adpcm_coder (short indata[], unsigned long indata_addr, char outdata[], un
...
@@ -111,6 +111,7 @@ void adpcm_coder (short indata[], unsigned long indata_addr, char outdata[], un
adpcm_coderbb_2:
adpcm_coderbb_2:
// # PRED: ENTRY [100.0%] (fallthru,exec)
// # PRED: ENTRY [100.0%] (fallthru,exec)
SP
=
SP
+
0x30
;
memAccessCycles
+=
simDCache
((
SP
+
0x4
),
1
);
// Spilling Register
memAccessCycles
+=
simDCache
((
SP
+
0x4
),
1
);
// Spilling Register
memAccessCycles
+=
simDCache
((
SP
+
0xc
),
1
);
// Spilling Register
memAccessCycles
+=
simDCache
((
SP
+
0xc
),
1
);
// Spilling Register
memAccessCycles
+=
simDCache
((
SP
+
0xc
),
1
);
// Reading Spilt Register
memAccessCycles
+=
simDCache
((
SP
+
0xc
),
1
);
// Reading Spilt Register
...
...
instrument/examples/adpcm/instrumented/my_ctop_IR.c
View file @
7fbde717
...
@@ -62,6 +62,7 @@ int main() {
...
@@ -62,6 +62,7 @@ int main() {
mainbb_2:
mainbb_2:
// # PRED: ENTRY [100.0%] (fallthru,exec)
// # PRED: ENTRY [100.0%] (fallthru,exec)
cacheSimInit
();
cacheSimInit
();
SP
=
SP
+
0x30
;
memAccessCycles
+=
simICache
(
0x354
,
4
);
// PC Relative Load
memAccessCycles
+=
simICache
(
0x354
,
4
);
// PC Relative Load
memAccessCycles
+=
simICache
(
0x358
,
4
);
// PC Relative Load
memAccessCycles
+=
simICache
(
0x358
,
4
);
// PC Relative Load
memAccessCycles
+=
simDCache
(
ARR_SIZE_addr
,
1
);
memAccessCycles
+=
simDCache
(
ARR_SIZE_addr
,
1
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment