Skip to content

Commit f00fb4d

Browse files
Merge branch 'main' of github01.hclpnp.com:Modeling/rtistic-pub-doc
2 parents 51cd0ea + 2abf9b2 commit f00fb4d

File tree

10 files changed

+652
-17
lines changed

10 files changed

+652
-17
lines changed

art-comp-test/tests/unwired_port/unwired.art

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ capsule Server {
3737
`
3838
#include "testlib.art.h"
3939
`
40-
publish service unwired notify behavior port p~ : PROT;
40+
publish service unwired behavior port p~ : PROT;
4141
statemachine {
4242
state S;
4343
t1: S -> S on p.requestData
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<projectDescription>
3+
<name>optional_part</name>
4+
<comment></comment>
5+
<projects>
6+
</projects>
7+
<buildSpec>
8+
<buildCommand>
9+
<name>com.ibm.xtools.umldt.core.internal.builders.UMLDevelopmentBuilder</name>
10+
<triggers>clean,full,incremental,</triggers>
11+
<arguments>
12+
</arguments>
13+
</buildCommand>
14+
</buildSpec>
15+
<natures>
16+
<nature>com.ibm.xtools.umldt.core.internal.natures.MDDProjectNature</nature>
17+
</natures>
18+
</projectDescription>
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
eclipse.preferences.version=1
2+
encoding/<project>=UTF-8

art-comp-test/testsEmx/optional_part/Top.emx

Lines changed: 594 additions & 0 deletions
Large diffs are not rendered by default.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
let tc = TCF.define(TCF.CPP_TRANSFORM);
2+
tc.sources = [
3+
'platform:/resource/optional_part/Top.emx#_7qjrILE3Ee-3NaZnqNWhuw',
4+
];
5+
tc.prerequisites = [
6+
'platform:/resource/TestRTSUtils/testRTSlib.tcjs',
7+
];
8+
tc.compilationMakeType = MakeType.GNU_make;
9+
tc.createTargetProject = true;
10+
tc.targetConfiguration = 'WinT.x64-MinGw-12.2.0';
11+
tc.targetProject = 'optional_part_target';
12+
tc.topCapsule = 'platform:/resource/optional_part/Top.emx#_7rNycLE3Ee-3NaZnqNWhuw';

art-samples/MatMult/OutputCollector.art

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,12 +22,12 @@ capsule OutputCollector {
2222
`
2323
void OutputCollector::printMatrix( const char * myName, int numRows, int numCols, int matrix[ 4096 ] ) {
2424
std::cout << "[" << myName << "]" << std::endl;
25-
for (int i=0; i<numRows; i++) {
26-
for (int j=0; j<numCols; j++) {
27-
std::cout << matrix[i,j] << " ";
28-
}
29-
std::cout << std::endl;
25+
for (int i=0; i<numRows*numCols; i++) {
26+
if((i % numCols) == 0 )
27+
std::cout << std::endl;
28+
std::cout << matrix[i] << " \t";
3029
}
30+
std::cout << std::endl;
3131
}
3232
`
3333

@@ -81,7 +81,8 @@ capsule OutputCollector {
8181
int pid = r->getPid();
8282
int finalValue = r->getFinalValue();
8383

84-
std::cout << "[" << myName << "] got " << finalValue << " from proc" << pid << std::endl;
84+
std::cout << "[" << myName << "] got " << finalValue << " from proc " << pid << std::endl;
85+
8586
C[pid] = finalValue;
8687
outputCount++;
8788
`;

art-samples/MatMult/Processor.art

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -243,6 +243,7 @@ capsule Processor {
243243
compute: j1 -> c1
244244
`
245245
// have both values now, can multiply and add to running total
246+
std::cout << "[" << myName << "] computing... total + (a*b) = " << total << " + (" << a << " * " << b << ") = " << total + (a*b) << std::endl;
246247
total = total + (a*b);
247248
// increment value counter
248249
valCount++;
@@ -254,6 +255,7 @@ capsule Processor {
254255
Result r;
255256
r.setPid(myPid);
256257
r.setFinalValue(total);
258+
std::cout << "[" << myName << "] finalValue = " << total << " from proc " << myPid << std::endl;
257259
outputP.result(r).send();
258260
`;
259261

art-samples/MatMult/README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,9 @@ Credit to [Queen's University](https://research.cs.queensu.ca/home/dingel/cisc84
1010

1111
`./Top.EXE -URTS_DEBUG=quit -UARGS 2 3 "[2,2,2,4,4,4]" "[5,5,5,5,5,5]"`
1212

13+
`./Top.EXE -URTS_DEBUG=quit -UARGS 2 3 "[1,2,3,4,5,6]" "[1,2,3,4,5,6]"`
14+
1315
`./Top.EXE -URTS_DEBUG=quit -UARGS 3 3 "[2,2,2,2,2,2,2,2,2]" "[3,3,3,3,3,3,3,3,3]"`
1416

17+
`./Top.EXE -URTS_DEBUG=quit -UARGS 3 3 "[1,2,3,4,5,6,7,8,9]" "[1,2,3,4,5,6,7,8,9]"`
18+

art-samples/MatMult/Top.art

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,12 @@ capsule Top {
1919
`
2020
void Top::printMatrix( const char * myName, int numRows, int numCols, int matrix[ 4096 ] ) {
2121
std::cout << "[" << myName << "]" << std::endl;
22-
for (int i=0; i<numRows; i++) {
23-
for (int j=0; j<numCols; j++) {
24-
std::cout << matrix[i,j] << " ";
25-
}
26-
std::cout << std::endl;
22+
for (int i=0; i<numRows*numCols; i++) {
23+
if((i % numCols) == 0 )
24+
std::cout << std::endl;
25+
std::cout << matrix[i] << " \t";
2726
}
27+
std::cout << std::endl;
2828
}
2929
`
3030

@@ -46,8 +46,8 @@ capsule Top {
4646
/* Connectors */
4747
connect managerP with manager.topP;
4848
connect tickOutP with tickInP;
49-
connect manager.bProviderP with providerForA.managerP;
50-
connect manager.aProviderP with providerForB.managerP;
49+
connect manager.aProviderP with providerForA.managerP;
50+
connect manager.bProviderP with providerForB.managerP;
5151
connect manager.outputCollector with outputCollector.managerP;
5252

5353
/* State Machine */

docs-sources/targetrts-api/_r_t_config_8h_source.html

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -422,9 +422,11 @@
422422
<div class="line"><a id="l00344" name="l00344"></a><span class="lineno"> 344</span> </div>
423423
<div class="line"><a id="l00345" name="l00345"></a><span class="lineno"> 345</span><span class="comment">// If this setting is enabled an array config_info will be included in mainLine.cc file,</span></div>
424424
<div class="line"><a id="l00346" name="l00346"></a><span class="lineno"> 346</span><span class="comment">// containing a textual encoding of all configuration settings used when compiling the TargetRTS.</span></div>
425-
<div class="line"><a id="l00347" name="l00347"></a><span class="lineno"> 347</span><span class="preprocessor">#define RTCONFIG_INFO 0</span></div>
426-
<div class="line"><a id="l00348" name="l00348"></a><span class="lineno"> 348</span> </div>
427-
<div class="line"><a id="l00349" name="l00349"></a><span class="lineno"> 349</span><span class="preprocessor">#endif </span><span class="comment">// __RTConfig_h__</span></div>
425+
<div class="line"><a id="l00347" name="l00347"></a><span class="lineno"> 347</span><span class="preprocessor">#ifndef RTCONFIG_INFO</span></div>
426+
<div class="line"><a id="l00348" name="l00348"></a><span class="lineno"> 348</span><span class="preprocessor">#define RTCONFIG_INFO 0</span></div>
427+
<div class="line"><a id="l00349" name="l00349"></a><span class="lineno"> 349</span><span class="preprocessor">#endif</span></div>
428+
<div class="line"><a id="l00350" name="l00350"></a><span class="lineno"> 350</span> </div>
429+
<div class="line"><a id="l00351" name="l00351"></a><span class="lineno"> 351</span><span class="preprocessor">#endif </span><span class="comment">// __RTConfig_h__</span></div>
428430
</div><!-- fragment --></div><!-- contents -->
429431
<!-- start footer part -->
430432
<hr class="footer"/><address class="footer"><small>

0 commit comments

Comments
 (0)