Dear Linaro toolchain support team:

 

I am Justin Guo from S3 graphics Inc. I am studying linaro’s big-little codes and is using TC2 Platform.   

I used ./linaro_kernel_build_cmds.sh to build kernel,  I got no problem when I set CONFIG_DEBUG_INFO=y to build for kernel.

However, When I trace kernel, the traced line in source code level is jumping up/down, so I tried to turn off the optimization.

 

After modified Makefile as below to  turn off optimization:

ifdef CONFIG_CC_OPTIMIZE_FOR_SIZE

KBUILD_CFLAGS  += -Os $(call cc-disable-warning,maybe-uninitialized,)

else

KBUILD_CFLAGS  += -O0

endif

 

I got errors when build linaro kernel for TC2:

root@ubuntu:/home/justinguo/linaro/1309# ./linaro_kernel_build_cmds.sh

Directory linaro-kernel exists. If the kernel code exists in this directory you may continue

without cloning the git repository for the kernel. Are you sure you want to do this? (y/n)

y

M       Makefile

HEAD is now at dafe325... Merge branch 'linux-linaro-lsk' into linux-linaro-lsk-android

  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current

                                 Dload  Upload   Total   Spent    Left  Speed

100 57281  100 57281    0     0  90703      0 --:--:-- --:--:-- --:--:--  188k

  Using /home/justinguo/linaro/1309/linaro-kernel as source for kernel

  GEN     /home/justinguo/linaro/1309/linaro-kernel/out/Makefile

  CHK     include/generated/uapi/linux/version.h

  CHK     include/generated/utsrelease.h

  UPD     include/generated/utsrelease.h

make[2]: `include/generated/mach-types.h' is up to date.

  CC      kernel/bounds.s

  GEN     include/generated/bounds.h

  CC      arch/arm/kernel/asm-offsets.s

  GEN     include/generated/asm-offsets.h

  CALL    /home/justinguo/linaro/1309/linaro-kernel/scripts/checksyscalls.sh

  CC      scripts/mod/empty.o

  MKELF   scripts/mod/elfconfig.h

  CC      scripts/mod/devicetable-offsets.s

  GEN     scripts/mod/devicetable-offsets.h

  HOSTCC  scripts/mod/file2alias.o

  HOSTCC  scripts/mod/modpost.o

  HOSTCC  scripts/mod/sumversion.o

  HOSTLD  scripts/mod/modpost

  CC      init/main.o

  CHK     include/generated/compile.h

  CC      init/version.o

  CC      init/do_mounts.o

  CC      init/do_mounts_rd.o

  CC      init/do_mounts_initrd.o

  LD      init/mounts.o

  CC      init/initramfs.o

  CC      init/calibrate.o

  CC      init/init_task.o

  LD      init/built-in.o

  CC      arch/arm/vfp/vfpmodule.o

  AS      arch/arm/vfp/entry.o

  AS      arch/arm/vfp/vfphw.o

    CC      arch/arm/vfp/vfpsingle.o

  CC      arch/arm/vfp/vfpdouble.o

  LD      arch/arm/vfp/vfp.o

  LD      arch/arm/vfp/built-in.o

  CC      arch/arm/kernel/elf.o

  AS      arch/arm/kernel/entry-armv.o

  AS      arch/arm/kernel/entry-common.o

  CC      arch/arm/kernel/irq.o

  CC      arch/arm/kernel/opcodes.o

  CC      arch/arm/kernel/process.o

  CC      arch/arm/kernel/ptrace.o

  CC      arch/arm/kernel/return_address.o

/home/justinguo/linaro/1309/linaro-kernel/arch/arm/kernel/return_address.c:63:2: warning:

#warning "TODO: return_address should use unwind tables" [-Wcpp]

  CC      arch/arm/kernel/sched_clock.o

  CC      arch/arm/kernel/setup.o

  CC      arch/arm/kernel/signal.o

  CC      arch/arm/kernel/stacktrace.o

  CC      arch/arm/kernel/sys_arm.o

  CC      arch/arm/kernel/time.o

  CC      arch/arm/kernel/traps.o

  CC      arch/arm/kernel/atags_parse.o

  CC      arch/arm/kernel/cpuidle.o

  CC      arch/arm/kernel/armksyms.o

  CC      arch/arm/kernel/module.o

  AS      arch/arm/kernel/sleep.o

  CC      arch/arm/kernel/suspend.o

  CC      arch/arm/kernel/smp.o

  CC      arch/arm/kernel/smp_tlb.o

  CC      arch/arm/kernel/smp_scu.o

  CC      arch/arm/kernel/smp_twd.o

  CC      arch/arm/kernel/arch_timer.o

  CC      arch/arm/kernel/ftrace.o

  CC      arch/arm/kernel/insn.o

  CC      arch/arm/kernel/unwind.o

  CC      arch/arm/kernel/devtree.o

  CC      arch/arm/kernel/swp_emulate.o

  CC      arch/arm/kernel/hw_breakpoint.o

  CC      arch/arm/kernel/perf_event.o

  CC      arch/arm/kernel/perf_event_cpu.o

  CC      arch/arm/kernel/topology.o

  CC      arch/arm/kernel/io.o

  CC      arch/arm/kernel/psci.o

/tmp/cciaYmCJ.s: Assembler messages:

/tmp/cciaYmCJ.s:147: Error: .err encountered

/tmp/cciaYmCJ.s:148: Error: .err encountered

/tmp/cciaYmCJ.s:149: Error: .err encountered

/tmp/cciaYmCJ.s:150: Error: .err encountered

/tmp/cciaYmCJ.s:191: Error: .err encountered

/tmp/cciaYmCJ.s:192: Error: .err encountered

/tmp/cciaYmCJ.s:193: Error: .err encountered

/tmp/cciaYmCJ.s:194: Error: .err encountered

make[2]: *** [arch/arm/kernel/psci.o] Error 1

make[1]: *** [arch/arm/kernel] Error 2

make: *** [sub-make] Error 2

root@ubuntu:/home/justinguo/linaro/1309#

 

Could you Please help fix these issues?

 

Best regards,

Justin Guo