Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
a79817c8
Kaydet (Commit)
a79817c8
authored
May 29, 2014
tarafından
haochen
Kaydeden (comit)
Markus Mohrhard
Haz 17, 2014
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
GPU Calc:Support IF formula in GPUInterpret
Change-Id: I9b2cebb99812d28e25c961129f73585d60690846
üst
bf18bb2a
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
63 additions
and
0 deletions
+63
-0
formulagroupcl.cxx
sc/source/core/opencl/formulagroupcl.cxx
+19
-0
op_logical.cxx
sc/source/core/opencl/op_logical.cxx
+37
-0
op_logical.hxx
sc/source/core/opencl/op_logical.hxx
+7
-0
No files found.
sc/source/core/opencl/formulagroupcl.cxx
Dosyayı görüntüle @
a79817c8
...
...
@@ -1682,6 +1682,18 @@ public:
}
virtual
std
::
string
BinFuncName
(
void
)
const
SAL_OVERRIDE
{
return
"leq"
;
}
};
class
OpLess
:
public
Binary
{
public
:
virtual
std
::
string
GetBottom
(
void
)
SAL_OVERRIDE
{
return
"0"
;
}
virtual
std
::
string
Gen2
(
const
std
::
string
&
lhs
,
const
std
::
string
&
rhs
)
const
SAL_OVERRIDE
{
std
::
stringstream
ss
;
ss
<<
"("
<<
lhs
<<
"<"
<<
rhs
<<
")"
;
return
ss
.
str
();
}
virtual
std
::
string
BinFuncName
(
void
)
const
SAL_OVERRIDE
{
return
"less"
;
}
};
class
OpGreater
:
public
Binary
{
public
:
...
...
@@ -2267,6 +2279,9 @@ DynamicKernelSoPArguments::DynamicKernelSoPArguments(
case
ocLessEqual
:
mvSubArguments
.
push_back
(
SoPHelper
(
ts
,
ft
->
Children
[
i
],
new
OpLessEqual
));
break
;
case
ocLess
:
mvSubArguments
.
push_back
(
SoPHelper
(
ts
,
ft
->
Children
[
i
],
new
OpLess
));
break
;
case
ocEqual
:
mvSubArguments
.
push_back
(
SoPHelper
(
ts
,
ft
->
Children
[
i
],
new
OpEqual
));
break
;
...
...
@@ -2872,6 +2887,10 @@ DynamicKernelSoPArguments::DynamicKernelSoPArguments(
mvSubArguments
.
push_back
(
SoPHelper
(
ts
,
ft
->
Children
[
i
],
new
OpAveDev
));
break
;
case
ocIf
:
mvSubArguments
.
push_back
(
SoPHelper
(
ts
,
ft
->
Children
[
i
],
new
OpIf
));
break
;
case
ocExternal
:
if
(
!
(
pChild
->
GetExternal
().
compareTo
(
OUString
(
"com.sun.star.sheet.addin.Analysis.getEffect"
))))
...
...
sc/source/core/opencl/op_logical.cxx
Dosyayı görüntüle @
a79817c8
...
...
@@ -314,6 +314,43 @@ void OpXor::GenSlidingWindowFunction(std::stringstream &ss,
ss
<<
" return t;
\n
"
;
ss
<<
"}
\n
"
;
}
void
OpIf
::
GenSlidingWindowFunction
(
std
::
stringstream
&
ss
,
const
std
::
string
&
sSymName
,
SubArguments
&
vSubArguments
)
{
ss
<<
"
\n
double "
<<
sSymName
;
ss
<<
"_"
<<
BinFuncName
()
<<
"("
;
if
(
vSubArguments
.
size
()
!=
3
)
throw
Unhandled
(
"unknown operand for ocPush"
);
for
(
unsigned
i
=
0
;
i
<
vSubArguments
.
size
();
i
++
)
{
if
(
i
)
ss
<<
","
;
vSubArguments
[
i
]
->
GenSlidingWindowDecl
(
ss
);
}
ss
<<
") {
\n
"
;
ss
<<
" int gid0 = get_global_id(0);
\n
"
;
FormulaToken
*
tmpCur0
=
vSubArguments
[
0
]
->
GetFormulaToken
();
if
(
tmpCur0
->
GetType
()
==
formula
::
svDoubleVectorRef
)
{
throw
UnhandledToken
(
tmpCur0
,
"unknown operand for ocPush"
);
}
else
{
ss
<<
" if(isNan("
;
ss
<<
vSubArguments
[
0
]
->
GenSlidingWindowDeclRef
();
ss
<<
")|| "
;
ss
<<
vSubArguments
[
0
]
->
GenSlidingWindowDeclRef
();
ss
<<
" == 0)
\n
"
;
ss
<<
" return "
;
ss
<<
vSubArguments
[
2
]
->
GenSlidingWindowDeclRef
();
ss
<<
";
\n
"
;
ss
<<
" else"
;
ss
<<
" return "
;
ss
<<
vSubArguments
[
1
]
->
GenSlidingWindowDeclRef
();
ss
<<
";
\n
"
;
}
ss
<<
"}
\n
"
;
}
}}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
sc/source/core/opencl/op_logical.hxx
Dosyayı görüntüle @
a79817c8
...
...
@@ -44,6 +44,13 @@ public:
const
std
::
string
&
sSymName
,
SubArguments
&
vSubArguments
)
SAL_OVERRIDE
;
virtual
std
::
string
BinFuncName
(
void
)
const
SAL_OVERRIDE
{
return
"Xor"
;
}
};
class
OpIf
:
public
Normal
{
public
:
virtual
void
GenSlidingWindowFunction
(
std
::
stringstream
&
ss
,
const
std
::
string
&
sSymName
,
SubArguments
&
vSubArguments
)
SAL_OVERRIDE
;
virtual
std
::
string
BinFuncName
(
void
)
const
SAL_OVERRIDE
{
return
"IF"
;
}
};
}}
...
...
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