Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix the issue #32041: Fix riscv32_mcu link failure in build period. #33972

Closed
wants to merge 8 commits into from
Closed

Fix the issue #32041: Fix riscv32_mcu link failure in build period. #33972

wants to merge 8 commits into from

Conversation

zhoupeng
Copy link
Contributor

@zhoupeng zhoupeng commented Nov 4, 2019

Fix the issue #32041

  1. tflite:riscv:Fix riscv32_mcu build failed with undefined references
    Fix the ld error: undefined references to __wrap_puts for build commands like make -f tensorflow/lite/experimental/micro/tools/make/Makefile TARGET=riscv32_mcu hello_world_bin
    The Makefile variables XXX_TEST_SRCS/XXX_SRCS in targets/mcu_riscv_makefile.inc are overridden by the the examples's respective makefile.inc (eg. hello_world/Makefile.inc), which leads to the architecture specified __wrap__funs are not included correctly.
  2. tflite:riscv:Fix hidden symbol __dso_handle' isn't defined. For arduino sketch in of riscv_mcu examples, this patch fix this bug by declare the following global variable void* __dso_handle;`
  3. how to test:
    make -f tensorflow/lite/experimental/micro/tools/make/Makefile TARGET=riscv32_mcu hello_world_test_bin

make -f tensorflow/lite/experimental/micro/tools/make/Makefile TARGET=riscv32_mcu hello_world_bin

Fix the ld error:
undefined references to __wrap_puts for build commands like `make -f tensorflow/lite/experimental/micro/tools/make/Makefile TARGET=riscv32_mcu hello_world_bin`
The related issue is #32041

The Makefile variables XXX_TEST_SRCS/XXX_SRCS in targets/mcu_riscv_makefile.inc are overridden by the the examples's respective makefile.inc (eg. hello_world/Makefile.inc), which leads to the
architecture specified __wrap__funs are not included correctly.
For arduino sketch in of riscv_mcu examples, this patch fix this bug by declare the following global variable
`void* __dso_handle;`.
@tensorflow-bot tensorflow-bot bot added the size:M CL Change Size: Medium label Nov 4, 2019
@rthadur rthadur self-assigned this Nov 5, 2019
@rthadur rthadur added this to Assigned Reviewer in PR Queue via automation Nov 5, 2019
@rthadur rthadur requested a review from miaout17 November 5, 2019 00:12
@rthadur rthadur added the comp:lite TF Lite related issues label Nov 5, 2019
@zhoupeng zhoupeng changed the title Fix wrapfunction Fix the issue #32041: Fix riscv32_mcu ld failure Nov 5, 2019
@zhoupeng zhoupeng changed the title Fix the issue #32041: Fix riscv32_mcu ld failure Fix the issue #32041: Fix riscv32_mcu link failure in build Nov 5, 2019
@zhoupeng zhoupeng changed the title Fix the issue #32041: Fix riscv32_mcu link failure in build Fix the issue #32041: Fix riscv32_mcu link failure in build period. Nov 5, 2019
Copy link
Contributor

@nkreeger nkreeger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @zhoupeng - is this related to #33680?

Some comments in that one apply here. Again sorry for any lag with TensorFlow World last week.

PR Queue automation moved this from Assigned Reviewer to Reviewer Requested Changes Nov 7, 2019
… for update changes later.

This reverts commit 6325b29.
…rences" for update change later.

This reverts commit 2a18731.
Fix the ld error:
undefined references to __wrap_puts for build commands like `make -f tensorflow/lite/experimental/micro/tools/make/Makefile TARGET=riscv32_mcu hello_world_bin`
The related issue is #32041

The Makefile variables XXX_TEST_SRCS/XXX_SRCS in targets/mcu_riscv_makefile.inc are overridden by the the examples's respective makefile.inc (eg. hello_world/Makefile.inc), which leads to the
architecture special __wrap__funs are not included correctly.
For arduino sketch in of riscv_mcu examples, this patch fix this bug by declare the global variable `void* __dso_handle;`.
For the `.bss' will not fit in region ram error, how to set freedom-e300-hifive1/flash.lds link scrip to get build pass.
@zhoupeng
Copy link
Contributor Author

@nkreeger
Patch updated as you suggest, pls review again.

@gbaned gbaned added the awaiting review Pull request awaiting review label Dec 5, 2019
@gbaned
Copy link
Contributor

gbaned commented Dec 18, 2019

@zhoupeng Can you please resolve conflicts? Thanks!

@gbaned gbaned added stat:awaiting response Status - Awaiting response from author and removed awaiting review Pull request awaiting review labels Dec 18, 2019
@tensorflowbutler tensorflowbutler added the stale This label marks the issue/pr stale - to be closed automatically if no activity label Jan 2, 2020
@tensorflowbutler
Copy link
Member

It has been 15 days with no activity and the awaiting response label was assigned. Is this PR still valid? Assigning the stalled label. Please comment to reassure me that this is still being worked on.

NobuoTsukamoto added a commit to NobuoTsukamoto/tensorflow that referenced this pull request Jan 3, 2020
@gbaned
Copy link
Contributor

gbaned commented Feb 5, 2020

@zhoupeng gentle ping to resolve conflicts. Thanks!

PR Queue automation moved this from Reviewer Requested Changes to Closed/Rejected Mar 7, 2020
@tensorflowbutler
Copy link
Member

It has been 29 days that this pull-request has stalled. Please create a new pull-request with the requested changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla: yes comp:lite TF Lite related issues size:M CL Change Size: Medium stale This label marks the issue/pr stale - to be closed automatically if no activity stat:awaiting response Status - Awaiting response from author
Projects
PR Queue
  
Closed/Rejected
Development

Successfully merging this pull request may close these issues.

None yet

6 participants