/*
 *               Copyright (C) 2005, BroadOn Communications Corp.
 *
 *  These coded instructions, statements, and computer programs contain
 *  unpublished  proprietary information of BroadOn Communications Corp.,
 *  and  are protected by Federal copyright law. They may not be disclosed
 *  to  third  parties or copied or duplicated in any form, in whole or in
 *  part, without the prior written consent of BroadOn Communications Corp.
 *
 */

#include "ios.h"
#include "ioslibc.h"

#define STACK_SIZE 1024
const u8 _initStack[STACK_SIZE];
const u32 _initStackSize = sizeof(_initStack);
const u32 _initPriority = 11;

void
main(u32 arg)
{
    u32 ar;
    u32 *a = &ar;
    printf("writing to %p\n", a);
    *a = 0xcafebabe;
    printf("*a = %08x\n", *a);
    a = (u32 *) ((u32)a |0x1);
    printf("writing to unaligned addr: %p\n", a);
    *a = 0xdeadbeef;
    printf("*a = %08x\n", *a);
    IOS_DestroyThread(0, NULL);
}
