aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authornivas-x86 <[email protected]>2024-01-29 17:43:37 -0800
committerGitHub <[email protected]>2024-01-29 17:43:37 -0800
commit1d75fb35c35573839a66182f0fa232f7b376d08f (patch)
tree9dc7e8e0be89efca510dbc05e372981bb12e2657
parent086530ed1304c6fa53fbc54efbe8db7196649076 (diff)
downloadxbyak-1d75fb35c35573839a66182f0fa232f7b376d08f.tar.gz
xbyak-1d75fb35c35573839a66182f0fa232f7b376d08f.zip
support align for auto_grow
-rw-r--r--xbyak/xbyak.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/xbyak/xbyak.h b/xbyak/xbyak.h
index 0e96ff5..66948ad 100644
--- a/xbyak/xbyak.h
+++ b/xbyak/xbyak.h
@@ -3215,7 +3215,7 @@ public:
{
if (x == 1) return;
if (x < 1 || (x & (x - 1))) XBYAK_THROW(ERR_BAD_ALIGN)
- if (isAutoGrow()) XBYAK_THROW(ERR_BAD_ALIGN)
+ if (isAutoGrow() && inner::getPageSize() % x != 0) XBYAK_THROW(ERR_BAD_ALIGN)
size_t remain = size_t(getCurr()) % x;
if (remain) {
nop(x - remain, useMultiByteNop);