Function: get_stream_overflow_switch

Applicable Products

Product

Supported (√/x)

Ascend 950PR/Ascend 950DT

√

Atlas A3 training products/Atlas A3 inference products

√

Atlas A2 training products/Atlas A2 inference products

√

Atlas training products

x

Atlas inference products

x

Atlas 200I/500 A2 inference products

x

Description

Checks whether overflow detection is enabled for a specified stream.

Prototype

  • C Prototype
    1
    aclError aclrtGetStreamOverflowSwitch(aclrtStream stream, uint32_t flag)
    
  • Python Function
    1
    flag, ret = acl.rt.get_stream_overflow_switch(stream)
    

Parameters

Parameter

Description

stream

Int, pointer address of the stream to be operated. If 0 is passed, the default stream will be operated.

Return Values

Return Value

Description

flag

Int, overflow detection switch. The options are as follows:

  • 0: disabled
  • 1: enabled

ret

Int, error code. 0 on success; else, failure.