What is a "register chanend"?

Technical questions regarding the xTIMEcomposer, xSOFTip Explorer and Programming with XMOS.
User avatar
dsteinwe
Active Member
Posts: 32
Joined: Wed Jun 29, 2016 8:59 am

What is a "register chanend"?

Postby dsteinwe » Mon Feb 25, 2019 5:45 pm

Hi,

I'm studding the code from the usb audio demo. In the source file "usb_buffer.xc", I have found the function:

Code: Select all

buffer(register chanend c_aud_out, register chanend c_aud_in, ...)
Can anybody explain me, what a "register chanend" is? So far, I have not found any documentation about it.

Thanks,
Dieter
CousinItt
Experienced Member
Posts: 125
Joined: Wed May 31, 2017 6:55 pm

Postby CousinItt » Mon Feb 25, 2019 7:21 pm

From the XC reference:
The auto and register specifiers give the declared objects automatic storage class, and may be used only within functions. Such declarations also serve as definitions and cause storage to be reserved.
Why it's necessary to do this for this particular function I'm not sure. There doesn't appear to be any other similar examples in the library code.
User avatar
dsteinwe
Active Member
Posts: 32
Joined: Wed Jun 29, 2016 8:59 am

Postby dsteinwe » Tue Feb 26, 2019 9:17 am

I have found the document (https://www.xmos.com/developer/download ... %5D%29.pdf), that you refer. Unfortunately, I don't understand it.

Who is online

Users browsing this forum: No registered users and 1 guest