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 some functions do not override correctly in arm-optimized-routines #9245

Closed
wants to merge 3 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 10 additions & 17 deletions libs/libarm-optimized-routines/aor.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Copyright 2022 PingCAP, Inc.
// Copyright 2024 PingCAP, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -47,54 +47,47 @@ extern "C" __attribute__((visibility("default"))) int memcmp(const void * src1,
return inline_memcmp(src1, src2, size);
}

extern "C" __attribute__((visibility("default"))) inline char * strcpy(
char * __restrict dst_,
const char * __restrict src_)
extern "C" __attribute__((visibility("default"))) char * strcpy(char * __restrict dst_, const char * __restrict src_)
{
return inline_strcpy(dst_, src_);
}

extern "C" __attribute__((visibility("default"))) inline char * stpcpy(
char * __restrict dst_,
const char * __restrict src_)
extern "C" __attribute__((visibility("default"))) char * stpcpy(char * __restrict dst_, const char * __restrict src_)
{
return inline_stpcpy(dst_, src_);
}

extern "C" __attribute__((visibility("default"))) inline int strcmp(const char * src1_, const char * src2_)
extern "C" __attribute__((visibility("default"))) int strcmp(const char * src1_, const char * src2_)
{
return inline_strcmp(src1_, src2_);
}

extern "C" __attribute__((visibility("default"))) inline char * strchr(const char * src_, int c)
extern "C" __attribute__((visibility("default"))) char * strchr(const char * src_, int c)
{
return inline_strchr(src_, c);
}

extern "C" __attribute__((visibility("default"))) inline char * strrchr(const char * src_, int c)
extern "C" __attribute__((visibility("default"))) char * strrchr(const char * src_, int c)
{
return inline_strrchr(src_, c);
}

extern "C" __attribute__((visibility("default"))) inline char * strchrnul(const char * src_, int c)
extern "C" __attribute__((visibility("default"))) char * strchrnul(const char * src_, int c)
{
return inline_strchrnul(src_, c);
}

extern "C" __attribute__((visibility("default"))) inline size_t strlen(const char * src_)
extern "C" __attribute__((visibility("default"))) size_t strlen(const char * src_)
{
return inline_strlen(src_);
}

extern "C" __attribute__((visibility("default"))) inline size_t strnlen(const char * src_, size_t size)
extern "C" __attribute__((visibility("default"))) size_t strnlen(const char * src_, size_t size)
{
return inline_strnlen(src_, size);
}

extern "C" __attribute__((visibility("default"))) inline int strncmp(
const char * src1_,
const char * src2_,
size_t size)
extern "C" __attribute__((visibility("default"))) int strncmp(const char * src1_, const char * src2_, size_t size)
{
return inline_strncmp(src1_, src2_, size);
}