Skip to content

Commit

Permalink
Merge #19852
Browse files Browse the repository at this point in the history
19852: clang floating point handling fix r=MrKevinWeiss a=MrKevinWeiss


### Contribution description

As promised (with a delay for vacation), here is the nightlies fix.  It is very easy...

I guess previously native had different handling of floating points (similar to cross-compiled gcc) when using clang.  thanks to `@maribu` great work on fixing the llvm toolchain issues, that seems to not be an issue anymore (though I don't know the commit that fixed it).

Thus we remove clang conditions and enjoy a green CI.

### Testing procedure

It seems like this wasn't tested or doesn't get tested in the normal murdock/bors procedure (still don't know why) but can be easily verified with a/b testing (master vs this PR)

```
TOOLCHAIN=llvm make all test -C tests/pkg/cayenne-lpp/
```

and
```
TOOLCHAIN=llvm make all test -C tests/pkg/lora-serialization/
```

I also tested with cross compiling on  the samr21 and they all work...

### Issues/PRs references

Look at nightlies...

Co-authored-by: MrKevinWeiss <weiss.kevin604@gmail.com>
  • Loading branch information
bors[bot] and MrKevinWeiss authored Aug 1, 2023
2 parents c4a1802 + 63f89b0 commit 876a8b1
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
4 changes: 1 addition & 3 deletions tests/pkg/cayenne-lpp/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,7 @@
#include "cayenne_lpp.h"

#define TEST_BUFFER1 { 0x03, 0x67, 0x01, 0x10, 0x05, 0x67, 0x00, 0xff }
#if defined(BOARD_NATIVE) && !defined(__clang__) /* clang uses same floating
* point handling as GCC
* with cross compiling */
#if defined(BOARD_NATIVE)
#define TEST_BUFFER2 { 0x01, 0x67, 0xFF, 0xD8, \
0x06, 0x71, 0x04, 0xD1, 0xFB, 0x2F, 0x00, 0x00 }
#else
Expand Down
2 changes: 1 addition & 1 deletion tests/pkg/lora-serialization/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
#include <stdio.h>
#include "lora_serialization.h"

#if defined(BOARD_NATIVE) && !defined(__clang__)
#if defined(BOARD_NATIVE)
#define TEST_01_EXPECTED { 0x1f, 0x4c, 0x0e, 0x27 }
#define TEST_02_EXPECTED { 0x65, 0xa6, 0xfa, 0xfd, \
0x6a, 0x24, 0x04, 0x09, \
Expand Down

0 comments on commit 876a8b1

Please sign in to comment.