# Multiple clocks in an assertion

**URL:** <https://verificationacademy.com/forums/t/multiple-clocks-in-an-assertion/38276>\
**Category:** SystemVerilog\
**Tags:** Assertion-Multiple-clocks, SystemVerilog\
**Created:** [October 28, 2020, 9:40am UTC](https://verificationacademy.com/forums/t/multiple-clocks-in-an-assertion/38276 "2020-10-28T09:40:16Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![user49](https://verificationacademy.com/forums/user_avatar/verificationacademy.com/user49/32/4533_2.png) [@user49](https://verificationacademy.com/forums/u/user49)\
**Post date:** [October 28, 2020, 2:47pm UTC](https://verificationacademy.com/forums/t/multiple-clocks-in-an-assertion/38276/2 "2020-10-28T14:47:55Z")

</div>

_In reply to [rrkk66418](https://verificationacademy.com/forums/t/multiple-clocks-in-an-assertion/38276):_

Yes, there is a standard on that, and it is limited to ##0 or ##1.  
**sv1800’2017** 16.13.1 Multiclocked sequences  
Multiclocked sequences are built by concatenating singly clocked subsequences using the single-delay concatenation operator ##1 or the zero-delay concatenation operator ##0. The single delay indicated by ##1 is understood to be from the end point of the first sequence, which occurs at a tick of the first clock, to the nearest strictly subsequent tick of the second clock, where the second sequence begins. The zero delay indicated by ##0 is understood to be from the end point of the first sequence, which occurs at a tick of the first clock, to the nearest possibly overlapping tick of the second clock, where the second sequence begins.

On your other question:

```verilog

@(posedge slow_clk_A) $changed(A)|-> ##1 @(posedge fast_clk_B) $changed(B)
// is same as 
@(posedge slow_clk_A) $changed(A)|-> 
             @(posedge slow_clk_A) 1 ##1 @(posedge fast_clk_B) $changed(B)
// The sampling is at the nearest strictly subsequent tick of the second clock,

// vs
@(posedge slow_clk_A) $changed(A)|-> @(posedge fast_clk_B) ##1 $changed(B)
the nearest possibly overlapping tick of the second clock, where the second sequence begins.

```

## See the explanation with an example that I provided in my SVA book [http://systemverilog.us/vf/Multiclock.pdf](http://systemverilog.us/vf/Multiclock.pdf)

Ben Cohen  
[http://www.systemverilog.us/](http://www.systemverilog.us/) [ben@systemverilog.us](mailto:ben@systemverilog.us)  
For training, consulting, services: contact [http://cvcblr.com/home](http://cvcblr.com/home)

\*\* SVA Handbook 4th Edition, 2016 ISBN 978-1518681448  
…

1. SVA Package: Dynamic and range delays and repeats [https://rb.gy/a89jlh](https://rb.gy/a89jlh)
2. Free books: Component Design by Example [https://rb.gy/9tcbhl](https://rb.gy/9tcbhl)  
Real Chip Design and Verification Using Verilog and VHDL($3) [https://rb.gy/cwy7nb](https://rb.gy/cwy7nb)
3. Papers:

- SVA Alternative for Complex Assertions  
[Browse all content in Verification Academy: Articles, Cookbooks, Resources, Sessions, and Tracks](https://verificationacademy.com/news/verification-horizons-march-2018-issue)
- SVA in a UVM Class-based Environment  
[SVA in a UVM Class-based Environment](https://verificationacademy.com/verification-horizons/february-2013-volume-9-issue-1/SVA-in-a-UVM-Class-based-Environment)
- Understanding the SVA Engine,  
[Browse all content in Verification Academy: Articles, Cookbooks, Resources, Sessions, and Tracks](https://verificationacademy.com/verification-horizons/july-2020-volume-16-issue-2)

---

_[View the full topic](https://verificationacademy.com/forums/t/multiple-clocks-in-an-assertion/38276)._
