|
Post by amitk3553 on Apr 30, 2013 6:19:33 GMT
Hello All,
Following is the rule in LRM of systemC:
An earlier notification will always override one scheduled to occur later, and an immediate notification is always earlier than any delta-cycle delayed or timed notification.
There is an example:
Process_A {my_event.notify();}
Process_B {my_event.notify(SC_ZERO_TIME);}
Process_C {wait(my_event);}
Now two cases of execution are shown below:
If process A executes first, then the event is triggered immediately, causing process C to be executed in the same delta-cycle. Then, process B is executed, and since the event was triggered immediately, there is no conflict and the second notification is accepted, causing process C to be executed again in the next delta-cycle.
If, however, process B executes first, then the delta-cycle delayed notification is scheduled first. Then, process A executes and the immediate notification overrides the delta-cycle delayed notification, causing process C to be executed only once, in the current delta-cycle.
So which is right one and how???
Regards Amit Kumar
|
|
|
Post by mohitn on Apr 30, 2013 11:25:54 GMT
Hello All, Following is the rule in LRM of systemC: An earlier notification will always override one scheduled to occur later, and an immediate notification is always earlier than any delta-cycle delayed or timed notification. There is an example: Process_A {my_event.notify();}
Process_B {my_event.notify(SC_ZERO_TIME);}
Process_C {wait(my_event);}Now two cases of execution are shown below: If process A executes first, then the event is triggered immediately, causing process C to be executed in the same delta-cycle. Then, process B is executed, and since the event was triggered immediately, there is no conflict and the second notification is accepted, causing process C to be executed again in the next delta-cycle.
If, however, process B executes first, then the delta-cycle delayed notification is scheduled first. Then, process A executes and the immediate notification overrides the delta-cycle delayed notification, causing process C to be executed only once, in the current delta-cycle.So which is right one and how??? Regards Amit Kumar Hello Amit, I think first represent the correct stages of execution as what Process_B {my_event.notify(SC_ZERO_TIME);} as what is happening in the above step is delta notification cancels pending timed notification thus my event is notified in the next delta cycle....
|
|
|
Post by karandeep963 on May 6, 2013 10:27:00 GMT
Both would be correct , it solely depends how these would be executed.
Regards, KS
|
|
|
Post by amitk3553 on May 6, 2013 12:05:01 GMT
Both would be correct , it solely depends how these would be executed. Regards, KS First approach is correct...k....because it follows the schedular's basic sequence to execute this But I want to know hows 2nd correct? without executing immediate, its going to delta?? Please explain..
|
|