# What is difference between $psprintf and $sformatf

**URL:** <https://verificationacademy.com/forums/t/what-is-difference-between-psprintf-and-sformatf/40024>\
**Category:** OVM\
**Tags:** OVM, sprintf\
**Created:** [February 2, 2022, 11:49am UTC](https://verificationacademy.com/forums/t/what-is-difference-between-psprintf-and-sformatf/40024 "2022-02-02T11:49:22Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![indrajeetpande](https://verificationacademy.com/forums/letter_avatar_proxy/v4/letter/i/54ee81/32.png) [@indrajeetpande](https://verificationacademy.com/forums/u/indrajeetpande)\
**Post date:** [February 2, 2022, 11:49am UTC](https://verificationacademy.com/forums/t/what-is-difference-between-psprintf-and-sformatf/40024/1 "2022-02-02T11:49:22Z")

</div>

what is difference between $psprintf and $sformatf ?

---

<div class="post-metadata">

**Author:** ![cgales](https://verificationacademy.com/forums/letter_avatar_proxy/v4/letter/c/ccd318/32.png) [@cgales](https://verificationacademy.com/forums/u/cgales)\
**Post date:** [February 2, 2022, 12:40pm UTC](https://verificationacademy.com/forums/t/what-is-difference-between-psprintf-and-sformatf/40024/2 "2022-02-02T12:40:54Z")

</div>

_In reply to [indrajeetpande](https://verificationacademy.com/forums/t/what-is-difference-between-psprintf-and-sformatf/40024):_

The function $sformatf() is in the SystemVerilog LRM and its functionality is fully defined.

The function $psprintf() IS NOT in the SystemVerilog LRM, and there is no clear definition on how it should function. However, it is a legacy function that most simulators support since removing it would break a lot of code. You should not use this as you are relying on implicit support by simulators.
