You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
128 lines
5.6 KiB
HTML
128 lines
5.6 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
|
|
|
|
<!--Converted with LaTeX2HTML 2018 (Released Feb 1, 2018) -->
|
|
<HTML>
|
|
<HEAD>
|
|
<TITLE>Method: allocate_wrk</TITLE>
|
|
<META NAME="description" CONTENT="Method: allocate_wrk">
|
|
<META NAME="keywords" CONTENT="userhtml">
|
|
<META NAME="resource-type" CONTENT="document">
|
|
<META NAME="distribution" CONTENT="global">
|
|
|
|
<META NAME="Generator" CONTENT="LaTeX2HTML v2018">
|
|
<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css">
|
|
|
|
<LINK REL="STYLESHEET" HREF="userhtml.css">
|
|
|
|
<LINK REL="next" HREF="node32.html">
|
|
<LINK REL="previous" HREF="node30.html">
|
|
<LINK REL="up" HREF="node27.html">
|
|
<LINK REL="next" HREF="node32.html">
|
|
</HEAD>
|
|
|
|
<BODY >
|
|
|
|
<DIV CLASS="navigation"><!--Navigation Panel-->
|
|
<A NAME="tex2html479"
|
|
HREF="node32.html">
|
|
<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" SRC="next.png"></A>
|
|
<A NAME="tex2html475"
|
|
HREF="node27.html">
|
|
<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" SRC="up.png"></A>
|
|
<A NAME="tex2html469"
|
|
HREF="node30.html">
|
|
<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" SRC="prev.png"></A>
|
|
<A NAME="tex2html477"
|
|
HREF="node2.html">
|
|
<IMG WIDTH="65" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="contents" SRC="contents.png"></A>
|
|
<BR>
|
|
<B> Next:</B> <A NAME="tex2html480"
|
|
HREF="node32.html">Method: free_wrk</A>
|
|
<B> Up:</B> <A NAME="tex2html476"
|
|
HREF="node27.html">Auxiliary Methods</A>
|
|
<B> Previous:</B> <A NAME="tex2html470"
|
|
HREF="node30.html">Method: sizeof</A>
|
|
<B> <A NAME="tex2html478"
|
|
HREF="node2.html">Contents</A></B>
|
|
<BR>
|
|
<BR></DIV>
|
|
<!--End of Navigation Panel-->
|
|
|
|
<H3><A NAME="SECTION00089400000000000000">
|
|
Method: allocate_wrk</A>
|
|
</H3><BIG CLASS="LARGE"><BIG CLASS="LARGE"></BIG></BIG>
|
|
<P>
|
|
<BIG CLASS="LARGE"><BIG CLASS="LARGE"></BIG></BIG>
|
|
<DIV ALIGN="CENTER"><BIG CLASS="LARGE"><BIG CLASS="LARGE"><BIG CLASS="LARGE"><code>call p%allocate_wrk(info[, vmold])</code>
|
|
<BR></BIG></BIG></BIG></DIV><BIG CLASS="LARGE"><BIG CLASS="LARGE"></BIG></BIG>
|
|
<P>
|
|
<BIG CLASS="LARGE"><BIG CLASS="LARGE"><BIG CLASS="LARGE">
|
|
Allocate internal work vectors. Each application of the preconditioner
|
|
uses a number of work vectors which are allocated internally as
|
|
necessary; therefore allocation and deallocation of memory occurs
|
|
multiple times during the execution of a Krylov method. In most cases
|
|
this strategy is perfectly acceptable, but
|
|
on some platforms, most notably GPUs, memory allocation is
|
|
a slow operation, and the default behaviour would lead to a
|
|
slowdown. This method allows to trade space for time by preallocating
|
|
the internal workspace outside of the invocation of a Krylov
|
|
method. When using GPUs or other specialized devices, the <code>vmold</code>
|
|
argument is also necessary to ensure the internal work vectors are of
|
|
the appropriate dynamic type to exploit the accelerator hardware; when
|
|
allocation occurs internally this is taken care of based on the dynamic
|
|
type of the <code>x</code> argument to the <code>apply</code> method.
|
|
</BIG></BIG></BIG>
|
|
<P>
|
|
<BIG CLASS="LARGE"><BIG CLASS="LARGE"><BIG CLASS="LARGE"><BIG CLASS="LARGE"><B>Arguments</B></BIG> </BIG></BIG></BIG>
|
|
<P></P>
|
|
<BIG CLASS="LARGE"><BIG CLASS="LARGE"></BIG></BIG>
|
|
<P>
|
|
<BIG CLASS="LARGE"><BIG CLASS="LARGE"></BIG></BIG><TABLE CELLPADDING=3>
|
|
<TR><TD ALIGN="LEFT" VALIGN="TOP" WIDTH=34><BIG CLASS="LARGE"><BIG CLASS="LARGE"><BIG CLASS="LARGE">
|
|
<code>info</code> </BIG></BIG></BIG></TD>
|
|
<TD ALIGN="LEFT" VALIGN="TOP" WIDTH=340><BIG CLASS="LARGE"><BIG CLASS="LARGE"><BIG CLASS="LARGE"> <code>integer, intent(out)</code>.</BIG></BIG></BIG></TD>
|
|
</TR>
|
|
<TR><TD ALIGN="LEFT" VALIGN="TOP" WIDTH=34><BIG CLASS="LARGE"><BIG CLASS="LARGE"><BIG CLASS="LARGE">
|
|
</BIG></BIG></BIG></TD>
|
|
<TD ALIGN="LEFT" VALIGN="TOP" WIDTH=340><BIG CLASS="LARGE"><BIG CLASS="LARGE"><BIG CLASS="LARGE"> Error code. If no error, 0 is returned. See Section <A HREF="node34.html#sec:errors">8</A> for details.</BIG></BIG></BIG></TD>
|
|
</TR>
|
|
<TR><TD ALIGN="LEFT" VALIGN="TOP" WIDTH=34><BIG CLASS="LARGE"><BIG CLASS="LARGE"><BIG CLASS="LARGE">
|
|
<code>vmold</code> </BIG></BIG></BIG></TD>
|
|
<TD ALIGN="LEFT" VALIGN="TOP" WIDTH=340><BIG CLASS="LARGE"><BIG CLASS="LARGE"><BIG CLASS="LARGE"> <code>class(psb_</code><SPAN CLASS="textit">x</SPAN><code>_base_vect_type), intent(in), optional</code>. </BIG></BIG></BIG></TD>
|
|
</TR>
|
|
<TR><TD ALIGN="LEFT" VALIGN="TOP" WIDTH=34><BIG CLASS="LARGE"><BIG CLASS="LARGE"><BIG CLASS="LARGE">
|
|
</BIG></BIG></BIG></TD>
|
|
<TD ALIGN="LEFT" VALIGN="TOP" WIDTH=340><BIG CLASS="LARGE"><BIG CLASS="LARGE"><BIG CLASS="LARGE"> The desired dynamic type for internal vector
|
|
components; this allows e.g. running on GPUs. </BIG></BIG></BIG></TD>
|
|
</TR>
|
|
</TABLE><BIG CLASS="LARGE"><BIG CLASS="LARGE"></BIG></BIG>
|
|
<P>
|
|
<BIG CLASS="LARGE"><BIG CLASS="LARGE"></BIG></BIG>
|
|
<DIV CLASS="navigation"><HR>
|
|
<!--Navigation Panel-->
|
|
<A NAME="tex2html479"
|
|
HREF="node32.html">
|
|
<IMG WIDTH="37" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="next" SRC="next.png"></A>
|
|
<A NAME="tex2html475"
|
|
HREF="node27.html">
|
|
<IMG WIDTH="26" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="up" SRC="up.png"></A>
|
|
<A NAME="tex2html469"
|
|
HREF="node30.html">
|
|
<IMG WIDTH="63" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="previous" SRC="prev.png"></A>
|
|
<A NAME="tex2html477"
|
|
HREF="node2.html">
|
|
<IMG WIDTH="65" HEIGHT="24" ALIGN="BOTTOM" BORDER="0" ALT="contents" SRC="contents.png"></A>
|
|
<BR>
|
|
<B> Next:</B> <A NAME="tex2html480"
|
|
HREF="node32.html">Method: free_wrk</A>
|
|
<B> Up:</B> <A NAME="tex2html476"
|
|
HREF="node27.html">Auxiliary Methods</A>
|
|
<B> Previous:</B> <A NAME="tex2html470"
|
|
HREF="node30.html">Method: sizeof</A>
|
|
<B> <A NAME="tex2html478"
|
|
HREF="node2.html">Contents</A></B> </DIV>
|
|
<!--End of Navigation Panel-->
|
|
|
|
</BODY>
|
|
</HTML>
|