BTW, I just wrote an application which is exactly the same with
autoinit_simple_conddestroy. And it can run successfully in my board.

  1 #include <stdio.h>
  2 #include <pthread.h>
  3 int main(void)
  4 {
  5 >-------pthread_cond_t cond = PTHREAD_COND_INITIALIZER;
  6 >-------if(pthread_cond_destroy(&cond) == 0)
  7 >------->-------printf("suc!\n");
  8 >-------else
  9 >------->-------printf("err!\n");
 10 }

sh-4.4# ./main
suc!


2021-05-10 17:28 GMT+08:00, Fangsuo Wu <tiger20081...@gmail.com>:
> Jan,
> I removed the CFLAGS and LDFLAGS, with configure command:
>
> ./configure --build=i686-pc-linux-gnu --host=arm-linux-gnueabihf
> --with-core=cobalt --enable-smp --enable-lazy-setsched
> --enable-debug=symbols
>
> But the issue still remains. I changed the failed test case as below,
> the issue still exists.
>
> 226 static void autoinit_simple_conddestroy(void)
> 227 {
> 228 >-------pthread_cond_t cond = PTHREAD_COND_INITIALIZER;
> 229 #if 0
> 230 >-------pthread_cond_t cond2 = PTHREAD_COND_INITIALIZER;
> 231 >-------unsigned int invalmagic = ~0x86860505; // ~COBALT_COND_MAGIC
> 232
> 233 >-------memcpy((char *)&cond2 + sizeof(cond2) - sizeof(invalmagic),
> 234 >------->-------&invalmagic, sizeof(invalmagic));
> 235
> 236 >-------smokey_trace("%s", __func__);
> 237 #endif
> 238 >-------check("cond_destroy", cond_destroy(&cond), 0);
> 239 //>-----check("cond_destroy invalid", cond_destroy(&cond2), -EINVAL);
> 240 }
>
> I'll try QEMU later to see if the issue also exits in QEMU.
>
> BTW, I saw some below warnings in compiling, do they have any
> relationship with the issue?
>   /bin/bash ../../../libtool   --mode=install /usr/bin/install -c
> smokey_net_server '/home/data/nfs_test//usr/xenomai/bin'
> libtool: warning: '../../../lib/cobalt/libcobalt.la' has not been
> installed in '/usr/xenomai/lib'
> libtool: warning: '../../../lib/cobalt/libmodechk.la' has not been
> installed in '/usr/xenomai/lib'
>
>
>
>
> 2021-05-10 15:35 GMT+08:00, Jan Kiszka <jan.kis...@siemens.com>:
>> On 10.05.21 09:20, Fangsuo Wu wrote:
>>> Jan,
>>> Thanks for your reply. The environment I used is listed below. BTW, I
>>> can run latency test successfully.
>>>
>>> 1. The revision of Xenomai: xenomai-3.1.tar.bz2
>>> 2. Soc: dual ARM cortex A7
>>> 3. How I built application libraries:
>>>     ./configure CFLAGS="-march=armv7-a -mfpu=vfp3"
>>> LDFLAGS="-march=armv7-a -mfpu=vfp3"   --build=i686-pc-linux-gnu
>>> --host=arm-linux-gnueabihf --with-core=cobalt --enable-smp
>>> --enable-pshared
>>>    make DESTDIR=/home/data/nfs_test/ install
>>> 4. The kernel I used is 4.19 so I applied
>>> ipipe-core-4.19.55-arm-5.patch, and manually enabled
>>> CONFIG_IPIPE_ARM_KUSER_TSC. The full config file is:
>>>
>>
>> OK - our qemu-armhf target [1] is multicore A7 as well. Do you see the
>> problem in QEMU, too? Do any of the extra CFLAGS or LDFLAGS you pass
>> play a role here? We compile in CI only with "--enable-smp
>> --enable-lazy-setsched --enable-debug=symbols" - maybe
>> "--enable-pshared"...
>>
>> Jan
>>
>> [1] https://source.denx.de/Xenomai/xenomai-images/-/jobs/265962#L387
>>
>> --
>> Siemens AG, T RDA IOT
>> Corporate Competence Center Embedded Linux
>>
>

Reply via email to