Turns out Apple's sample code also receives parameter address that’s beyond the 
parameter count. This sample code, Creating Custom Audio Effects: 
https://developer.apple.com/documentation/audiotoolbox/audio_unit_v3_plug-ins/creating_custom_audio_effects
 
<https://developer.apple.com/documentation/audiotoolbox/audio_unit_v3_plug-ins/creating_custom_audio_effects>

I’ve tested it with auval and the `DSPKernel::handleOneEvent(AURenderEvent 
const *event)` function receives an event with parameter address set to 
2798869411.

Markus, is it possible that auval picks a random parameter address that’s 
invalid. I’m now debugging the sample code, but thought I’d ask in case there’s 
also an issue in auval.

> On 15 Jun 2021, at 2:17 pm, Nikolozi Meladze via Coreaudio-api 
> <coreaudio-api@lists.apple.com> wrote:
> 
> Thanks Rob & Markus for your help.
> 
> Turns out my AU crashes when the auval runs, so the render timeout error is a 
> bit misleading.
> 
> I have a vector which holds all parameter rampers. When auval runs, at some 
> point it request to set a value for a parameter with the address of 
> 3634796004. This is coming from AUParameterEvent.parameterAddress. This is 
> clearly a garbage value, I have my parameters enumerated in sequence from 0. 
> And the crash is caused by accessing index out of bounds of the vector. I 
> should probably add a check for that, but for now, clearly, this is exposing 
> another bug somewhere in my code. I’ll just continue debugging, I’m getting 
> close :)
> 
>> On 15 Jun 2021, at 12:37 pm, Robert Abernathy <r...@musicunfolding.com 
>> <mailto:r...@musicunfolding.com>> wrote:
>> 
>> My issue was in allocateRenderResources() not in the internalRenderBlock. 
>> The AU had actually been running fine on iOS for a few years when I ported 
>> it to macOS and saw the issue in auval. It was even running fine on macOS in 
>> Logic, GarageBand, MainStage, and Reaper. That’s why I mentioned it here 
>> because it feels a bit similar to this situation. The error was definitely 
>> in my code. It’s just that none of the hosts had exercised the code in 
>> question in the pattern that caught the bug before auval did.
>> 
>> Auval is great and in this case it did find a bug in my code. It’s just that 
>> the error reporting was off and some things at the time hinted that it might 
>> be a combination of how my code was failing and that the AU was a sandboxed 
>> AUv3 port.
>> 
>> It would actually be very nice to have a way of using auval on iOS to test 
>> conformance of AUv3’s there. Even if we could only have it in the simulator, 
>> it would be great to have.
>> 
>> Cheers,
>> Rob
>> 
>>> On Jun 15, 2021, at 2:18 AM, Markus Fritze <mfri...@apple.com 
>>> <mailto:mfri...@apple.com>> wrote:
>>> 
>>>> One thing to keep in mind while trying to trace issues with auvaltool and 
>>>> errors with Mac Catalyst is that the reported error may not be where the 
>>>> actual problem is. I spent several months trying to trace a failure with 
>>>> an iOS AUv3 I was porting using Catalyst that wouldn’t pass auval because 
>>>> the channel configuration wasn’t passing the tests. But, auval wasn’t even 
>>>> reporting the channels that I had configured.
>>> 
>>> auval is not perfect, but it is a tool that helps finding a bunch of issues 
>>> much easier than during using the plugin. But it can’t test everything.
>>> 
>>> 
>>>> In the end I gave up trying to chase down the issue and reprogrammed the 
>>>> entire AU. In doing this, I found that I actually had a timing issue in 
>>>> the allocation method for the DSP code.
>>> 
>>> We have special code in our DSP section, which throws an error whenever 
>>> somebody tries to allocate memory during a render callback – which 
>>> obviously is a massive no-no.
>>> 
>>> 
>>> Markus
>>> 
>>>> When I went back and fixed this in the original code for the AU, auval 
>>>> passed with no issues.
>>>> 
>>>> I’d look everywhere in your code for things that might not be right, not 
>>>> just in the areas that the auval error suggests.
>>>> 
>>>> Cheers,
>>>> Rob
>>>> 
>>>>> On Jun 14, 2021, at 6:44 AM, Nikolozi Meladze via Coreaudio-api 
>>>>> <coreaudio-api@lists.apple.com <mailto:coreaudio-api@lists.apple.com>> 
>>>>> wrote:
>>>>> 
>>>>> Hi,
>>>>> 
>>>>> I’m trying to run my iPad AUv3 synth on macOS Big Sur using Mac Catalyst. 
>>>>> I’ve fixed a few issues and made some progress. But I’m currently stuck 
>>>>> on the auval returning this error:
>>>>> 
>>>>> ```
>>>>> Checking parameter setting
>>>>> Using AudioUnitSetParameter
>>>>> Using AudioUnitScheduleParameter
>>>>> ERROR: -66745 IN CALL AudioUnitRender
>>>>> 
>>>>> * * FAIL
>>>>> ```
>>>>> 
>>>>> What does this particular test do? Is there documentation that I can 
>>>>> read, to see what each auval test does?
>>>>> 
>>>>> I know -66745 corresponds to kAudioUnitErr_RenderTimeout but that still 
>>>>> doesn’t tell me much.
>>>>> 
>>>>> The AUv3 loads and works fine in Reaper, but doesn’t work in Logic 
>>>>> because auval fails it because of the above error. Any pointers would be 
>>>>> appreciated. 
>>>>> 
>>>>> Cheers
>>>>> Niko
>>>>> _______________________________________________
>>>>> Do not post admin requests to the list. They will be ignored.
>>>>> Coreaudio-api mailing list      (Coreaudio-api@lists.apple.com 
>>>>> <mailto:Coreaudio-api@lists.apple.com>)
>>>>> Help/Unsubscribe/Update your Subscription:
>>>>> https://lists.apple.com/mailman/options/coreaudio-api/rob%40musicunfolding.com
>>>>>  
>>>>> <https://lists.apple.com/mailman/options/coreaudio-api/rob%40musicunfolding.com>
>>>>> 
>>>>> This email sent to r...@musicunfolding.com 
>>>>> <mailto:r...@musicunfolding.com>
>>>> 
>>>> _______________________________________________
>>>> Do not post admin requests to the list. They will be ignored.
>>>> Coreaudio-api mailing list      (Coreaudio-api@lists.apple.com 
>>>> <mailto:Coreaudio-api@lists.apple.com>)
>>>> Help/Unsubscribe/Update your Subscription:
>>>> https://lists.apple.com/mailman/options/coreaudio-api/mfritze%40apple.com 
>>>> <https://lists.apple.com/mailman/options/coreaudio-api/mfritze%40apple.com>
>>>> 
>>>> This email sent to mfri...@apple.com <mailto:mfri...@apple.com>
>> 
> 
> _______________________________________________
> Do not post admin requests to the list. They will be ignored.
> Coreaudio-api mailing list      (Coreaudio-api@lists.apple.com)
> Help/Unsubscribe/Update your Subscription:
> https://lists.apple.com/mailman/options/coreaudio-api/nikolozi.meladze%40icloud.com
> 
> This email sent to nikolozi.mela...@icloud.com

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Coreaudio-api mailing list      (Coreaudio-api@lists.apple.com)
Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/coreaudio-api/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to