Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
fengzch-das
nunchaku
Commits
2f9b307c
Commit
2f9b307c
authored
Nov 10, 2024
by
sxtyzhangzk
Committed by
Zhekai Zhang
Nov 10, 2024
Browse files
[major] workaround layout issue on gcc :(
parent
e3e2a92a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
6 deletions
+7
-6
src/kernels/gemm_w4a4.cu
src/kernels/gemm_w4a4.cu
+7
-6
No files found.
src/kernels/gemm_w4a4.cu
View file @
2f9b307c
...
...
@@ -605,7 +605,8 @@ public:
struct
EpilogueDefault
{
struct
Arguments
{};
// workaround for layout mismatch between host and device code
struct
Arguments
{
size_t
unused
;
};
__device__
__forceinline__
void
operator
()(
const
BlockInfo
binfo
,
fpsum_warp
fpsum
,
half_t
*
out
,
int
M
,
int
N
,
int
K
,
Arguments
args
)
{
...
...
@@ -617,7 +618,7 @@ public:
};
struct
EpilogueNop
{
struct
Arguments
{};
struct
Arguments
{
size_t
unused
;
};
__device__
__forceinline__
void
operator
()(
const
BlockInfo
binfo
,
fpsum_warp
fpsum
,
half_t
*
out
,
int
M
,
int
N
,
int
K
,
Arguments
args
)
{
...
...
@@ -1664,7 +1665,7 @@ public:
};
struct
EpilogueGelu
{
struct
Arguments
{};
struct
Arguments
{
size_t
unused
;
};
// static constexpr float SHIFT_VALUE = 0.171875f;
...
...
@@ -2417,7 +2418,7 @@ public:
struct
EpilogueGLU
{
struct
Arguments
{};
struct
Arguments
{
size_t
unused
;
};
__device__
__forceinline__
void
operator
()(
const
BlockInfo
binfo
,
fpsum_warp
fpsum
,
half_t
*
out
,
int
M
,
int
N
,
int
K
,
Arguments
args
)
{
...
...
@@ -2431,7 +2432,7 @@ public:
};
struct
EpilogueSilu
{
struct
Arguments
{};
struct
Arguments
{
size_t
unused
;
};
__device__
__forceinline__
void
operator
()(
const
BlockInfo
binfo
,
fpsum_warp
fpsum
,
half_t
*
out
,
int
M
,
int
N
,
int
K
,
Arguments
args
)
{
...
...
@@ -2723,7 +2724,7 @@ void gemm_w4a4(
}
dispatchBool
(
act_unsigned
,
[
&
]
<
bool
ACT_UNSIGNED
>
()
{
// test_sizeof<Epilogue::Arguments>();
// test_sizeof<
typename
Epilogue::Arguments>();
// std::apply([](auto ...args) {
// (test_sizeof<decltype(args)>(), ...);
// }, args);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment