Topic: std::make_integer_seq should provide O(logN) order
Author: Bolero MURAKAMI <bolero.murakami@gmail.com>
Date: Sun, 27 Jan 2013 04:42:12 -0800 (PST)
Raw View
------=_Part_1463_12354005.1359290532834
Content-Type: text/plain; charset=ISO-8859-7
Content-Transfer-Encoding: quoted-printable
In my opinion, std::make_integer_seq should provide =CF(logN) order (templa=
te instantiation depth).
=20
It becomes necessary for the generation of a "large integer sequence".
For example:
using t =3D make_integer_seq<int, 2000>;
=20
In the simplest implementation of recursion =CF(N), which can not be compil=
ed.
Because maximum depth defined by C++11 is 1024.
=20
- make_integer_seq implementation =CF(N)
----
template<class T, T N, class Seq =3D integer_seq<T>, bool Break =3D N =3D=
=3D 0>
struct make_integer_seq_impl {
using type =3D Seq;
};
template<class T, T N, T... I>
struct make_integer_seq_impl<T, N, integer_seq<T, I...>, false>
: make_integer_seq_impl<T, N - 1, integer_seq<T, N - 1, I...>>
{};
=20
template<class T, T N>
using make_integer_seq =3D typename make_integer_seq_impl<T, N>::type;
----
=20
If implementation of the =CF(logN), can be compiled.
=20
- make_integer_seq implementation =CF(logN)
----
template<class T, typename Seq, T Next>
struct make_integer_seq_next_even;
template<class T, T... I, T Next>
struct make_integer_seq_next_even<T, integer_seq<T, I...>, Next> {
using type =3D integer_seq<T, I..., (I + Next)...>;
};
=20
template<class T, typename Seq, T Next, T Last>
struct make_integer_seq_next_odd;
template<class T, T... I, T Next, T Last>
struct make_integer_seq_next_odd<T, integer_seq<T, I...>, Next, Last> {
using type =3D integer_seq<T, I..., (I + Next)..., Last>;
};
=20
template<class T, T N, class Enable =3D void>
struct make_integer_seq_impl;
template<class T, T N>
struct make_integer_seq_impl<T, N, typename enable_if<(N =3D=3D 0)>::type=
> {
using type =3D integer_seq<T>;
};
template<class T, T N>
struct make_integer_seq_impl<T, N, typename enable_if<(N =3D=3D 1)>::type=
> {
using type =3D integer_seq<T, 0>;
};
template<class T, T N>
struct make_integer_seq_impl<T, N, typename enable_if<(N > 1 && N % 2 =3D=
=3D 0)>::type>
: make_integer_seq_next_even<T, typename make_integer_seq_impl<T, N / 2=
>::type, N / 2>
{};
template<class T, T N>
struct make_integer_seq_impl<T, N, typename enable_if<(N > 1 && N % 2 =3D=
=3D 1)>::type>
: make_integer_seq_next_odd<T, typename make_integer_seq_impl<T, N / 2>=
::type, N / 2, N - 1>
{};
=20
template<class T, T N>
using make_integer_seq =3D typename make_integer_seq_impl<T, N>::type;
----
=20
Therefore, std::make_integer_seq should be implemented in =CF(logN) order (=
template recursion depth).
And I think it should be defined as =CF(logN) order by the C++ standard.
=20
It is the benefit for heavy users of template meta-programming, and it will=
not become to the detriment of other programmers.
=20
My Sprout library provides =CF(logN) ordered index_tuple (the same as make_=
integer_seq).
The feature's order is very useful for large data computation.
See: https://github.com/bolero-MURAKAMI/Sprout/blob/master/sprout/index_tup=
le/index_range.hpp
--=20
---=20
You received this message because you are subscribed to the Google Groups "=
ISO C++ Standard - Future Proposals" group.
To post to this group, send email to std-proposals@isocpp.org.
To unsubscribe from this group, send email to std-proposals+unsubscribe@iso=
cpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposa=
ls/?hl=3Den.
------=_Part_1463_12354005.1359290532834
Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC40">In my opinion, std:=
:make_integer_seq should provide =CE=9F(logN) order (template instantiation=
depth).</div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC41"> </d=
iv></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC42">It become=
s necessary for the generation of a "large integer sequence".</div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC43">For examp=
le:</div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC44"><span sty=
le=3D"font-family: courier new,monospace;"> using t =3D make_integer_seq&l=
t;int, 2000>;</span></div></pre><span style=3D"font-family: courier new,=
monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC45">&n=
bsp;</div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC46">In the si=
mplest implementation of recursion =CE=9F(N), which can not be compiled.</d=
iv></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC47">Because m=
aximum depth defined by C++11 is 1024.</div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC48"> </d=
iv></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC49">- make_in=
teger_seq implementation =CE=9F(N)</div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC50">----</div=
></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC51"><span sty=
le=3D"font-family: courier new,monospace;"> template<class T, T N, clas=
s Seq =3D integer_seq<T>, bool Break =3D N =3D=3D 0></span></div><=
/pre><span style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC52"><s=
pan style=3D"font-family: courier new,monospace;"> struct make_integer_seq=
_impl {</span></div></pre><span style=3D"font-family: courier new,monospace=
;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC53"><s=
pan style=3D"font-family: courier new,monospace;"> using type =3D Seq;</=
span></div></pre><span style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC54"><s=
pan style=3D"font-family: courier new,monospace;"> };</span></div></pre><s=
pan style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC55"><s=
pan style=3D"font-family: courier new,monospace;"> template<class T, T =
N, T... I></span></div></pre><span style=3D"font-family: courier new,mon=
ospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC56"><s=
pan style=3D"font-family: courier new,monospace;"> struct make_integer_seq=
_impl<T, N, integer_seq<T, I...>, false></span></div></pre><spa=
n style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC57"><s=
pan style=3D"font-family: courier new,monospace;"> : make_integer_seq_im=
pl<T, N - 1, integer_seq<T, N - 1, I...>></span></div></pre><sp=
an style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC58"><s=
pan style=3D"font-family: courier new,monospace;"> {};</span></div></pre><=
span style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC59"><s=
pan style=3D"font-family: courier new,monospace;"> </span></div></pre>=
<span style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC60"><s=
pan style=3D"font-family: courier new,monospace;"> template<class T, T =
N></span></div></pre><span style=3D"font-family: courier new,monospace;"=
>
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC61"><s=
pan style=3D"font-family: courier new,monospace;"> using make_integer_seq =
=3D typename make_integer_seq_impl<T, N>::type;</span></div></pre><sp=
an style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC62">--=
--</div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC63"> </d=
iv></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC64">If implem=
entation of the =CE=9F(logN), can be compiled.</div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC65"> </d=
iv></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC66">- make_in=
teger_seq implementation =CE=9F(logN)</div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC67">----</div=
></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC68"><span sty=
le=3D"font-family: courier new,monospace;"> template<class T, typename =
Seq, T Next></span></div></pre><span style=3D"font-family: courier new,m=
onospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC69"><s=
pan style=3D"font-family: courier new,monospace;"> struct make_integer_seq=
_next_even;</span></div></pre><span style=3D"font-family: courier new,monos=
pace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC70"><s=
pan style=3D"font-family: courier new,monospace;"> template<class T, T.=
... I, T Next></span></div></pre><span style=3D"font-family: courier new,=
monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC71"><s=
pan style=3D"font-family: courier new,monospace;"> struct make_integer_seq=
_next_even<T, integer_seq<T, I...>, Next> {</span></div></pre><=
span style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC72"><s=
pan style=3D"font-family: courier new,monospace;"> using type =3D intege=
r_seq<T, I..., (I + Next)...>;</span></div></pre><span style=3D"font-=
family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC73"><s=
pan style=3D"font-family: courier new,monospace;"> };</span></div></pre><s=
pan style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC74"><s=
pan style=3D"font-family: courier new,monospace;"> </span></div></pre>=
<span style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC75"><s=
pan style=3D"font-family: courier new,monospace;"> template<class T, ty=
pename Seq, T Next, T Last></span></div></pre><span style=3D"font-family=
: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC76"><s=
pan style=3D"font-family: courier new,monospace;"> struct make_integer_seq=
_next_odd;</span></div></pre><span style=3D"font-family: courier new,monosp=
ace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC77"><s=
pan style=3D"font-family: courier new,monospace;"> template<class T, T.=
... I, T Next, T Last></span></div></pre><span style=3D"font-family: cour=
ier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC78"><s=
pan style=3D"font-family: courier new,monospace;"> struct make_integer_seq=
_next_odd<T, integer_seq<T, I...>, Next, Last> {</span></div></=
pre><span style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC79"><s=
pan style=3D"font-family: courier new,monospace;"> using type =3D intege=
r_seq<T, I..., (I + Next)..., Last>;</span></div></pre><span style=3D=
"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC80"><s=
pan style=3D"font-family: courier new,monospace;"> };</span></div></pre><s=
pan style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC81"><s=
pan style=3D"font-family: courier new,monospace;"> </span></div></pre>=
<span style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC82"><s=
pan style=3D"font-family: courier new,monospace;"> template<class T, T =
N, class Enable =3D void></span></div></pre><span style=3D"font-family: =
courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC83"><s=
pan style=3D"font-family: courier new,monospace;"> struct make_integer_seq=
_impl;</span></div></pre><span style=3D"font-family: courier new,monospace;=
">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC84"><s=
pan style=3D"font-family: courier new,monospace;"> template<class T, T =
N></span></div></pre><span style=3D"font-family: courier new,monospace;"=
>
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC85"><s=
pan style=3D"font-family: courier new,monospace;"> struct make_integer_seq=
_impl<T, N, typename enable_if<(N =3D=3D 0)>::type> {</span></d=
iv></pre><span style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC86"><s=
pan style=3D"font-family: courier new,monospace;"> using type =3D intege=
r_seq<T>;</span></div></pre><span style=3D"font-family: courier new,m=
onospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC87"><s=
pan style=3D"font-family: courier new,monospace;"> };</span></div></pre><s=
pan style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC88"><s=
pan style=3D"font-family: courier new,monospace;"> template<class T, T =
N></span></div></pre><span style=3D"font-family: courier new,monospace;"=
>
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC89"><s=
pan style=3D"font-family: courier new,monospace;"> struct make_integer_seq=
_impl<T, N, typename enable_if<(N =3D=3D 1)>::type> {</span></d=
iv></pre><span style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC90"><s=
pan style=3D"font-family: courier new,monospace;"> using type =3D intege=
r_seq<T, 0>;</span></div></pre><span style=3D"font-family: courier ne=
w,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC91"><s=
pan style=3D"font-family: courier new,monospace;"> };</span></div></pre><s=
pan style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC92"><s=
pan style=3D"font-family: courier new,monospace;"> template<class T, T =
N></span></div></pre><span style=3D"font-family: courier new,monospace;"=
>
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC93"><s=
pan style=3D"font-family: courier new,monospace;"> struct make_integer_seq=
_impl<T, N, typename enable_if<(N > 1 && N % 2 =3D=3D 0)&g=
t;::type></span></div></pre><span style=3D"font-family: courier new,mono=
space;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC94"><s=
pan style=3D"font-family: courier new,monospace;"> : make_integer_seq_ne=
xt_even<T, typename make_integer_seq_impl<T, N / 2>::type, N / 2&g=
t;</span></div></pre><span style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC95"><s=
pan style=3D"font-family: courier new,monospace;"> {};</span></div></pre><=
span style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC96"><s=
pan style=3D"font-family: courier new,monospace;"> template<class T, T =
N></span></div></pre><span style=3D"font-family: courier new,monospace;"=
>
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC97"><s=
pan style=3D"font-family: courier new,monospace;"> struct make_integer_seq=
_impl<T, N, typename enable_if<(N > 1 && N % 2 =3D=3D 1)&g=
t;::type></span></div></pre><span style=3D"font-family: courier new,mono=
space;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC98"><s=
pan style=3D"font-family: courier new,monospace;"> : make_integer_seq_ne=
xt_odd<T, typename make_integer_seq_impl<T, N / 2>::type, N / 2, N=
- 1></span></div></pre><span style=3D"font-family: courier new,monospac=
e;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC99"><s=
pan style=3D"font-family: courier new,monospace;"> {};</span></div></pre><=
span style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC100"><=
span style=3D"font-family: courier new,monospace;"> </span></div></pre=
><span style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC101"><=
span style=3D"font-family: courier new,monospace;"> template<class T, T=
N></span></div></pre><span style=3D"font-family: courier new,monospace;=
">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC102"><=
span style=3D"font-family: courier new,monospace;"> using make_integer_seq=
=3D typename make_integer_seq_impl<T, N>::type;</span></div></pre><s=
pan style=3D"font-family: courier new,monospace;">
</span><pre><div class=3D"line" id=3D"file-gistfile1-txt-LC103">-=
---</div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC104"> </=
div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC105">Therefor=
e, std::make_integer_seq should be implemented in =CE=9F(logN) order (templ=
ate recursion depth).</div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC106">And I th=
ink it should be defined as =CE=9F(logN) order by the C++ standard.</div></=
pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC107"> </=
div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC108">It is th=
e benefit for heavy users of template meta-programming, and it will not bec=
ome to the detriment of other programmers.</div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC109"> </=
div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC110">My Sprou=
t library provides =CE=9F(logN) ordered index_tuple (the same as make_integ=
er_seq).</div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC111">The feat=
ure's order is very useful for large data computation.</div></pre>
<pre><div class=3D"line" id=3D"file-gistfile1-txt-LC112">See: htt=
ps://github.com/bolero-MURAKAMI/Sprout/blob/master/sprout/index_tuple/index=
_range.hpp<br><br></div></pre>
<p></p>
-- <br />
<br />
--- <br />
You received this message because you are subscribed to the Google Groups &=
quot;ISO C++ Standard - Future Proposals" group.<br />
To post to this group, send email to std-proposals@isocpp.org.<br />
To unsubscribe from this group, send email to std-proposals+unsubscribe@iso=
cpp.org.<br />
Visit this group at <a href=3D"http://groups.google.com/a/isocpp.org/group/=
std-proposals/?hl=3Den">http://groups.google.com/a/isocpp.org/group/std-pro=
posals/?hl=3Den</a>.<br />
<br />
<br />
------=_Part_1463_12354005.1359290532834--
.
Author: Nicol Bolas <jmckesson@gmail.com>
Date: Sun, 27 Jan 2013 13:33:42 -0800 (PST)
Raw View
------=_Part_368_30357450.1359322422179
Content-Type: text/plain; charset=ISO-8859-1
What exactly is make_integer_seq from? What proposal is this about?
--
---
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.
To post to this group, send email to std-proposals@isocpp.org.
To unsubscribe from this group, send email to std-proposals+unsubscribe@isocpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposals/?hl=en.
------=_Part_368_30357450.1359322422179
Content-Type: text/html; charset=ISO-8859-1
What exactly is make_integer_seq from? What proposal is this about?<pre><div><br></div></pre>
<p></p>
-- <br />
<br />
--- <br />
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.<br />
To post to this group, send email to std-proposals@isocpp.org.<br />
To unsubscribe from this group, send email to std-proposals+unsubscribe@isocpp.org.<br />
Visit this group at <a href="http://groups.google.com/a/isocpp.org/group/std-proposals/?hl=en">http://groups.google.com/a/isocpp.org/group/std-proposals/?hl=en</a>.<br />
<br />
<br />
------=_Part_368_30357450.1359322422179--
.
Author: =?ISO-8859-1?Q?Daniel_Kr=FCgler?= <daniel.kruegler@gmail.com>
Date: Sun, 27 Jan 2013 23:02:18 +0100
Raw View
2013/1/27 Nicol Bolas <jmckesson@gmail.com>:
> What exactly is make_integer_seq from? What proposal is this about?
See:
http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2013/n3493.html
I agree with Bolero that a logarithmic guarantee would be preferable.
This would be the first example of such a guarantee, but it seems
reasonable to have that.
- Daniel
--
---
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposals/?hl=en.
.
Author: Jonathan Wakely <cxx@kayari.org>
Date: Tue, 12 Mar 2013 06:23:55 -0700 (PDT)
Raw View
------=_Part_190_14516642.1363094635608
Content-Type: text/plain; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
On Sunday, January 27, 2013 10:02:18 PM UTC, Daniel Kr=FCgler wrote:
>
> 2013/1/27 Nicol Bolas <jmck...@gmail.com <javascript:>>:=20
> > What exactly is make_integer_seq from? What proposal is this about?=20
>
> See:=20
>
> http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2013/n3493.html=20
>
> I agree with Bolero that a logarithmic guarantee would be preferable.=20
> This would be the first example of such a guarantee, but it seems=20
> reasonable to have that.=20
>
Yes, my reference implementation is O(N) but it's been pointed out to me=20
that it should be O(logN).
I'm not planning on a new revision of the paper before the next meeting,=20
but was already planning on mentioning that the depth of instantiation can=
=20
be reduced.
--=20
---=20
You received this message because you are subscribed to the Google Groups "=
ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposa=
ls/?hl=3Den.
------=_Part_190_14516642.1363094635608
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
<br><br>On Sunday, January 27, 2013 10:02:18 PM UTC, Daniel Kr=FCgler wrote=
:<blockquote class=3D"gmail_quote" style=3D"margin: 0;margin-left: 0.8ex;bo=
rder-left: 1px #ccc solid;padding-left: 1ex;">2013/1/27 Nicol Bolas <<a =
href=3D"javascript:" target=3D"_blank" gdf-obfuscated-mailto=3D"zsUJ9yDmQ-A=
J">jmck...@gmail.com</a>>:
<br>> What exactly is make_integer_seq from? What proposal is this about=
?
<br>
<br>See:
<br>
<br><a href=3D"http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2013/n349=
3.html" target=3D"_blank">http://www.open-std.org/jtc1/<wbr>sc22/wg21/docs/=
papers/2013/<wbr>n3493.html</a>
<br>
<br>I agree with Bolero that a logarithmic guarantee would be preferable.
<br>This would be the first example of such a guarantee, but it seems
<br>reasonable to have that.
<br></blockquote><div><br>Yes, my reference implementation is O(N) but it's=
been pointed out to me that it should be O(logN).<br><br>I'm not planning =
on a new revision of the paper before the next meeting, but was already pla=
nning on mentioning that the depth of instantiation can be reduced.<br><br>=
<br></div>
<p></p>
-- <br />
<br />
--- <br />
You received this message because you are subscribed to the Google Groups &=
quot;ISO C++ Standard - Future Proposals" group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to std-proposals+unsubscribe@isocpp.org.<br />
To post to this group, send email to std-proposals@isocpp.org.<br />
Visit this group at <a href=3D"http://groups.google.com/a/isocpp.org/group/=
std-proposals/?hl=3Den">http://groups.google.com/a/isocpp.org/group/std-pro=
posals/?hl=3Den</a>.<br />
<br />
<br />
------=_Part_190_14516642.1363094635608--
.
Author: Martinho Fernandes <martinho.fernandes@gmail.com>
Date: Tue, 12 Mar 2013 14:27:07 +0100
Raw View
On Tue, Mar 12, 2013 at 2:23 PM, Jonathan Wakely <cxx@kayari.org> wrote:
>
>
> On Sunday, January 27, 2013 10:02:18 PM UTC, Daniel Kr=FCgler wrote:
>>
>> 2013/1/27 Nicol Bolas <jmck...@gmail.com>:
>> > What exactly is make_integer_seq from? What proposal is this about?
>>
>> See:
>>
>> http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2013/n3493.html
>>
>> I agree with Bolero that a logarithmic guarantee would be preferable.
>> This would be the first example of such a guarantee, but it seems
>> reasonable to have that.
>
If we're requiring a guarantee on this, why not go for something that
user code cannot actually achieve? Why not require O(1) instantiations
instead?
Mit freundlichen Gr=FC=DFen,
Martinho
--=20
---=20
You received this message because you are subscribed to the Google Groups "=
ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposa=
ls/?hl=3Den.
.
Author: Jonathan Wakely <cxx@kayari.org>
Date: Tue, 12 Mar 2013 06:33:03 -0700 (PDT)
Raw View
------=_Part_1524_21213709.1363095183040
Content-Type: text/plain; charset=ISO-8859-1
On Tuesday, March 12, 2013 1:27:07 PM UTC, R. Martinho Fernandes wrote:
>
>
> If we're requiring a guarantee on this, why not go for something that
> user code cannot actually achieve? Why not require O(1) instantiations
> instead?
Because the idea of the proposal is to standardise existing practice and I
hoped it would be uncontroversial. The more bells and whistles are added to
it the less likely it is to be accepted before the heat death of the
universe.
--
---
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposals/?hl=en.
------=_Part_1524_21213709.1363095183040
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
<br><br>On Tuesday, March 12, 2013 1:27:07 PM UTC, R. Martinho Fernandes wr=
ote:<blockquote class=3D"gmail_quote" style=3D"margin: 0;margin-left: 0.8ex=
;border-left: 1px #ccc solid;padding-left: 1ex;"><br>If we're requiring a g=
uarantee on this, why not go for something that
<br>user code cannot actually achieve? Why not require O(1) instantiations
<br>instead?
</blockquote><div><br> Because the idea of the proposal is to standard=
ise existing practice and I hoped it would be uncontroversial. The more bel=
ls and whistles are added to it the less likely it is to be accepted before=
the heat death of the universe.<br></div><div> </div>
<p></p>
-- <br />
<br />
--- <br />
You received this message because you are subscribed to the Google Groups &=
quot;ISO C++ Standard - Future Proposals" group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to std-proposals+unsubscribe@isocpp.org.<br />
To post to this group, send email to std-proposals@isocpp.org.<br />
Visit this group at <a href=3D"http://groups.google.com/a/isocpp.org/group/=
std-proposals/?hl=3Den">http://groups.google.com/a/isocpp.org/group/std-pro=
posals/?hl=3Den</a>.<br />
<br />
<br />
------=_Part_1524_21213709.1363095183040--
.
Author: Martinho Fernandes <martinho.fernandes@gmail.com>
Date: Tue, 12 Mar 2013 14:39:32 +0100
Raw View
On Tue, Mar 12, 2013 at 2:33 PM, Jonathan Wakely <cxx@kayari.org> wrote:
>
>
> On Tuesday, March 12, 2013 1:27:07 PM UTC, R. Martinho Fernandes wrote:
>>
>>
>> If we're requiring a guarantee on this, why not go for something that
>> user code cannot actually achieve? Why not require O(1) instantiations
>> instead?
>
>
> Because the idea of the proposal is to standardise existing practice and=
I
> hoped it would be uncontroversial. The more bells and whistles are added =
to
> it the less likely it is to be accepted before the heat death of the
> universe.
>
Ok, that's fair enough. As long as O(1) implementations are nor forbidden ;=
)
Mit freundlichen Gr=FC=DFen,
Martinho
--=20
---=20
You received this message because you are subscribed to the Google Groups "=
ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposa=
ls/?hl=3Den.
.
Author: Jonathan Wakely <cxx@kayari.org>
Date: Tue, 12 Mar 2013 06:40:45 -0700 (PDT)
Raw View
------=_Part_1232_30881873.1363095645845
Content-Type: text/plain; charset=ISO-8859-1
On Tuesday, March 12, 2013 1:39:32 PM UTC, R. Martinho Fernandes wrote:
>
> On Tue, Mar 12, 2013 at 2:33 PM, Jonathan Wakely <c...@kayari.org<javascript:>>
> wrote:
> >
> >
> > On Tuesday, March 12, 2013 1:27:07 PM UTC, R. Martinho Fernandes wrote:
> >>
> >>
> >> If we're requiring a guarantee on this, why not go for something that
> >> user code cannot actually achieve? Why not require O(1) instantiations
> >> instead?
> >
> >
> > Because the idea of the proposal is to standardise existing practice
> and I
> > hoped it would be uncontroversial. The more bells and whistles are added
> to
> > it the less likely it is to be accepted before the heat death of the
> > universe.
> >
>
> Ok, that's fair enough. As long as O(1) implementations are nor forbidden
> ;)
>
>
I certainly wouldn't object to O(1), and I'll mention it when the proposal
is discussed, but I want to gauge the committee's reaction to the basic
feature before requiring compiler magic as well. If the feature is
accepted and users consider it important compilers might offer an O(1)
make_integer_seq as a Quality of Implementation feature anyway.
TBH I was expecting feedback to say that the generic integer_seq<T, T...>
template is not needed and I should just choose one of int_seq<int...> or
uint_seq<unsigned...> and forget the others, but noone has commented on
that part so I'm pleased the feedback has been "this is great, make it
faster!" instead :-)
--
---
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposals/?hl=en.
------=_Part_1232_30881873.1363095645845
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable
<br><br>On Tuesday, March 12, 2013 1:39:32 PM UTC, R. Martinho Fernandes wr=
ote:<blockquote class=3D"gmail_quote" style=3D"margin: 0;margin-left: 0.8ex=
;border-left: 1px #ccc solid;padding-left: 1ex;">On Tue, Mar 12, 2013 at 2:=
33 PM, Jonathan Wakely <<a href=3D"javascript:" target=3D"_blank" gdf-ob=
fuscated-mailto=3D"alp-ERDghJUJ">c...@kayari.org</a>> wrote:
<br>>
<br>>
<br>> On Tuesday, March 12, 2013 1:27:07 PM UTC, R. Martinho Fernandes w=
rote:
<br>>>
<br>>>
<br>>> If we're requiring a guarantee on this, why not go for somethi=
ng that
<br>>> user code cannot actually achieve? Why not require O(1) instan=
tiations
<br>>> instead?
<br>>
<br>>
<br>> Because the idea of the proposal is to standardise existing =
practice and I
<br>> hoped it would be uncontroversial. The more bells and whistles are=
added to
<br>> it the less likely it is to be accepted before the heat death of t=
he
<br>> universe.
<br>>
<br>
<br>Ok, that's fair enough. As long as O(1) implementations are nor forbidd=
en ;)
<br>
<br></blockquote><div><br>I certainly wouldn't object to O(1), and I'll men=
tion it when the=20
proposal is discussed, but I want to gauge the committee's reaction to=20
the basic feature before requiring compiler magic as well. If the=20
feature is accepted and users consider it important compilers might=20
offer an O(1) make_integer_seq as a Quality of Implementation feature=20
anyway. <br><br>TBH I was expecting feedback to say that the generic=20
integer_seq<T, T...> template is not needed and I should just=20
choose one of int_seq<int...> or uint_seq<unsigned...> and=20
forget the others, but noone has commented on that part so I'm pleased=20
the feedback has been "this is great, make it faster!" instead :-)<br></div=
><br>
<p></p>
-- <br />
<br />
--- <br />
You received this message because you are subscribed to the Google Groups &=
quot;ISO C++ Standard - Future Proposals" group.<br />
To unsubscribe from this group and stop receiving emails from it, send an e=
mail to std-proposals+unsubscribe@isocpp.org.<br />
To post to this group, send email to std-proposals@isocpp.org.<br />
Visit this group at <a href=3D"http://groups.google.com/a/isocpp.org/group/=
std-proposals/?hl=3Den">http://groups.google.com/a/isocpp.org/group/std-pro=
posals/?hl=3Den</a>.<br />
<br />
<br />
------=_Part_1232_30881873.1363095645845--
.
Author: =?ISO-8859-1?Q?Mikael_Kilpel=E4inen?=
Date: Tue, 12 Mar 2013 14:54:25 +0100
Raw View
12.3.2013 14:40, Jonathan Wakely kirjoitti:
>
> TBH I was expecting feedback to say that the generic integer_seq<T,
> T...> template is not needed and I should just choose one of
> int_seq<int...> or uint_seq<unsigned...> and forget the others, but
> noone has commented on that part so I'm pleased the feedback has been
> "this is great, make it faster!" instead :-)
>
integer_seq<T, T...> is consistent with std::integral_constant<T, T>,
except of the integer != integral part.
Mikael
--
---
You received this message because you are subscribed to the Google Groups "ISO C++ Standard - Future Proposals" group.
To unsubscribe from this group and stop receiving emails from it, send an email to std-proposals+unsubscribe@isocpp.org.
To post to this group, send email to std-proposals@isocpp.org.
Visit this group at http://groups.google.com/a/isocpp.org/group/std-proposals/?hl=en.
.