taskoff.c 1.47 KB
#include <stddef.h>
#include "sptask.h"

main()
{
    printf("#define OS_TASK_SIZE\t\t\t%2d\n", sizeof(OSTask_t));

    printf("#define OS_TASK_OFF_TYPE\t\t%2d\n",
	offsetof(OSTask_t, type));

    printf("#define OS_TASK_OFF_FLAGS\t\t%2d\n",
	offsetof(OSTask_t, flags));

    printf("#define OS_TASK_OFF_UBOOT\t\t%2d\n",
	offsetof(OSTask_t, ucode_boot));

    printf("#define OS_TASK_OFF_UBOOT_SZ\t\t%2d\n",
	offsetof(OSTask_t, ucode_boot_size));

    printf("#define OS_TASK_OFF_UCODE\t\t%2d\n",
	offsetof(OSTask_t, ucode));

    printf("#define OS_TASK_OFF_UCODE_SZ\t\t%2d\n",
	offsetof(OSTask_t, ucode_size));

    printf("#define OS_TASK_OFF_UDATA\t\t%2d\n",
	offsetof(OSTask_t, ucode_data));

    printf("#define OS_TASK_OFF_UDATA_SZ\t\t%2d\n",
	offsetof(OSTask_t, ucode_data_size));

    printf("#define OS_TASK_OFF_STACK\t\t%2d\n",
	offsetof(OSTask_t, dram_stack));

    printf("#define OS_TASK_OFF_STACK_SZ\t\t%2d\n",
	offsetof(OSTask_t, dram_stack_size));

    printf("#define OS_TASK_OFF_OUTBUFF\t\t%2d\n",
	offsetof(OSTask_t, output_buff));

    printf("#define OS_TASK_OFF_OUTBUFF_SZ\t\t%2d\n",
	offsetof(OSTask_t, output_buff_size));

    printf("#define OS_TASK_OFF_DATA\t\t%2d\n",
	offsetof(OSTask_t, data_ptr));

    printf("#define OS_TASK_OFF_DATA_SZ\t\t%2d\n",
	offsetof(OSTask_t, data_size));

    printf("#define OS_TASK_OFF_YIELD\t\t%2d\n",
	offsetof(OSTask_t, yield_data_ptr));

    printf("#define OS_TASK_OFF_YIELD_SZ\t\t%2d\n",
	offsetof(OSTask_t, yield_data_size));
    return 0;
}