winehq.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2025
February
January
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
January
2003
December
November
October
September
August
July
June
May
April
March
February
January
2002
December
November
October
September
August
July
June
May
April
March
February
January
2001
December
November
October
September
August
July
June
May
April
March
February
List overview
wine-commits
April 2020
----- 2025 -----
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
2 participants
1016 discussions
Start a n
N
ew thread
Zebediah Figura : d3dcompiler/tests: Add some tests for matrix majority.
by Alexandre Julliard
14 Apr '20
14 Apr '20
Module: wine Branch: master Commit: 9f75e917cb5c1d93e2912476fe34baa85db80cd6 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=9f75e917cb5c1d93e2912476…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Tue Apr 14 09:21:27 2020 +0200 d3dcompiler/tests: Add some tests for matrix majority. Signed-off-by: Zebediah Figura <zfigura(a)codeweavers.com> Signed-off-by: Matteo Bruni <mbruni(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3dcompiler_43/tests/hlsl_d3d11.c | 9 ++- dlls/d3dcompiler_43/tests/hlsl_d3d9.c | 129 +++++++++++++++++++++++++++++++-- 2 files changed, 129 insertions(+), 9 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=9f75e917cb5c1d93e291…
1
0
0
0
Zebediah Figura : d3dcompiler: Calculate the register size of types.
by Alexandre Julliard
14 Apr '20
14 Apr '20
Module: wine Branch: master Commit: 5f18f9f75ac4ac43ce18e78c139702f45eb88d1d URL:
https://source.winehq.org/git/wine.git/?a=commit;h=5f18f9f75ac4ac43ce18e78c…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Thu Apr 2 16:14:13 2020 -0500 d3dcompiler: Calculate the register size of types. Signed-off-by: Zebediah Figura <zfigura(a)codeweavers.com> Signed-off-by: Matteo Bruni <mbruni(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3dcompiler_43/d3dcompiler_private.h | 3 +++ dlls/d3dcompiler_43/hlsl.y | 21 +++++++++++++++++++++ dlls/d3dcompiler_43/utils.c | 20 ++++++++++++++++++++ 3 files changed, 44 insertions(+) diff --git a/dlls/d3dcompiler_43/d3dcompiler_private.h b/dlls/d3dcompiler_43/d3dcompiler_private.h index 40c4fcffee..1f1d8e2663 100644 --- a/dlls/d3dcompiler_43/d3dcompiler_private.h +++ b/dlls/d3dcompiler_43/d3dcompiler_private.h @@ -614,6 +614,7 @@ struct hlsl_type unsigned int modifiers; unsigned int dimx; unsigned int dimy; + unsigned int reg_size; union { struct list *elements; @@ -632,6 +633,7 @@ struct hlsl_struct_field const char *name; const char *semantic; DWORD modifiers; + unsigned int reg_offset; }; struct source_location @@ -1083,6 +1085,7 @@ struct hlsl_type *new_hlsl_type(const char *name, enum hlsl_type_class type_clas struct hlsl_type *new_array_type(struct hlsl_type *basic_type, unsigned int array_size) DECLSPEC_HIDDEN; struct hlsl_type *clone_hlsl_type(struct hlsl_type *old, unsigned int default_majority) DECLSPEC_HIDDEN; struct hlsl_type *get_type(struct hlsl_scope *scope, const char *name, BOOL recursive) DECLSPEC_HIDDEN; +BOOL is_row_major(const struct hlsl_type *type) DECLSPEC_HIDDEN; BOOL find_function(const char *name) DECLSPEC_HIDDEN; unsigned int components_count_type(struct hlsl_type *type) DECLSPEC_HIDDEN; BOOL compare_hlsl_types(const struct hlsl_type *t1, const struct hlsl_type *t2) DECLSPEC_HIDDEN; diff --git a/dlls/d3dcompiler_43/hlsl.y b/dlls/d3dcompiler_43/hlsl.y index 833472a351..d3ef18bb6e 100644 --- a/dlls/d3dcompiler_43/hlsl.y +++ b/dlls/d3dcompiler_43/hlsl.y @@ -720,6 +720,13 @@ static BOOL add_struct_field(struct list *fields, struct hlsl_struct_field *fiel return TRUE; } +BOOL is_row_major(const struct hlsl_type *type) +{ + /* Default to column-major if the majority isn't explicitly set, which can + * happen for anonymous nodes. */ + return !!(type->modifiers & HLSL_MODIFIER_ROW_MAJOR); +} + static struct hlsl_type *apply_type_modifiers(struct hlsl_type *type, unsigned int *modifiers, struct source_location loc) { @@ -750,6 +757,9 @@ static struct hlsl_type *apply_type_modifiers(struct hlsl_type *type, new_type->modifiers = add_modifiers(new_type->modifiers, *modifiers, loc); *modifiers &= ~HLSL_TYPE_MODIFIERS_MASK; + + if (new_type->type == HLSL_CLASS_MATRIX) + new_type->reg_size = is_row_major(new_type) ? new_type->dimy : new_type->dimx; return new_type; } @@ -798,6 +808,8 @@ static struct list *gen_struct_fields(struct hlsl_type *type, DWORD modifiers, s static struct hlsl_type *new_struct_type(const char *name, struct list *fields) { struct hlsl_type *type = d3dcompiler_alloc(sizeof(*type)); + struct hlsl_struct_field *field; + unsigned int reg_size = 0; if (!type) { @@ -809,6 +821,13 @@ static struct hlsl_type *new_struct_type(const char *name, struct list *fields) type->dimx = type->dimy = 1; type->e.elements = fields; + LIST_FOR_EACH_ENTRY(field, fields, struct hlsl_struct_field, entry) + { + field->reg_offset = reg_size; + reg_size += field->type->reg_size; + } + type->reg_size = reg_size; + list_add_tail(&hlsl_ctx.types, &type->entry); return type; @@ -837,6 +856,8 @@ static BOOL add_typedef(DWORD modifiers, struct hlsl_type *orig_type, struct lis if (type->type != HLSL_CLASS_MATRIX) check_invalid_matrix_modifiers(type->modifiers, v->loc); + else + type->reg_size = is_row_major(type) ? type->dimy : type->dimx; if ((type->modifiers & HLSL_MODIFIER_COLUMN_MAJOR) && (type->modifiers & HLSL_MODIFIER_ROW_MAJOR)) diff --git a/dlls/d3dcompiler_43/utils.c b/dlls/d3dcompiler_43/utils.c index ff779891fd..0c8b918d13 100644 --- a/dlls/d3dcompiler_43/utils.c +++ b/dlls/d3dcompiler_43/utils.c @@ -820,6 +820,10 @@ struct hlsl_type *new_hlsl_type(const char *name, enum hlsl_type_class type_clas type->base_type = base_type; type->dimx = dimx; type->dimy = dimy; + if (type_class == HLSL_CLASS_MATRIX) + type->reg_size = is_row_major(type) ? dimy : dimx; + else + type->reg_size = 1; list_add_tail(&hlsl_ctx.types, &type->entry); @@ -836,6 +840,7 @@ struct hlsl_type *new_array_type(struct hlsl_type *basic_type, unsigned int arra type->modifiers = basic_type->modifiers; type->e.array.elements_count = array_size; type->e.array.type = basic_type; + type->reg_size = basic_type->reg_size * array_size; return type; } @@ -960,8 +965,13 @@ struct hlsl_type *clone_hlsl_type(struct hlsl_type *old, unsigned int default_ma case HLSL_CLASS_ARRAY: type->e.array.type = clone_hlsl_type(old->e.array.type, default_majority); type->e.array.elements_count = old->e.array.elements_count; + type->reg_size = type->e.array.elements_count * type->e.array.type->reg_size; break; + case HLSL_CLASS_STRUCT: + { + unsigned int reg_size = 0; + type->e.elements = d3dcompiler_alloc(sizeof(*type->e.elements)); if (!type->e.elements) { @@ -991,10 +1001,20 @@ struct hlsl_type *clone_hlsl_type(struct hlsl_type *old, unsigned int default_ma if (old_field->semantic) field->semantic = d3dcompiler_strdup(old_field->semantic); field->modifiers = old_field->modifiers; + field->reg_offset = reg_size; + reg_size += field->type->reg_size; list_add_tail(type->e.elements, &field->entry); } + type->reg_size = reg_size; break; + } + + case HLSL_CLASS_MATRIX: + type->reg_size = is_row_major(type) ? type->dimy : type->dimx; + break; + default: + type->reg_size = 1; break; }
1
0
0
0
Zebediah Figura : d3dcompiler: Always set the matrix majority for declaration types.
by Alexandre Julliard
14 Apr '20
14 Apr '20
Module: wine Branch: master Commit: f82b44748a51e64bc8ca18e141cbb319e9e7eb1a URL:
https://source.winehq.org/git/wine.git/?a=commit;h=f82b44748a51e64bc8ca18e1…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Thu Apr 2 16:14:12 2020 -0500 d3dcompiler: Always set the matrix majority for declaration types. Signed-off-by: Zebediah Figura <zfigura(a)codeweavers.com> Signed-off-by: Matteo Bruni <mbruni(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3dcompiler_43/d3dcompiler_private.h | 2 +- dlls/d3dcompiler_43/hlsl.y | 39 ++++++++++++++++++++++++++----- dlls/d3dcompiler_43/utils.c | 8 ++++--- 3 files changed, 39 insertions(+), 10 deletions(-) diff --git a/dlls/d3dcompiler_43/d3dcompiler_private.h b/dlls/d3dcompiler_43/d3dcompiler_private.h index df45a7082f..40c4fcffee 100644 --- a/dlls/d3dcompiler_43/d3dcompiler_private.h +++ b/dlls/d3dcompiler_43/d3dcompiler_private.h @@ -1081,7 +1081,7 @@ void free_declaration(struct hlsl_ir_var *decl) DECLSPEC_HIDDEN; struct hlsl_type *new_hlsl_type(const char *name, enum hlsl_type_class type_class, enum hlsl_base_type base_type, unsigned dimx, unsigned dimy) DECLSPEC_HIDDEN; struct hlsl_type *new_array_type(struct hlsl_type *basic_type, unsigned int array_size) DECLSPEC_HIDDEN; -struct hlsl_type *clone_hlsl_type(struct hlsl_type *old) DECLSPEC_HIDDEN; +struct hlsl_type *clone_hlsl_type(struct hlsl_type *old, unsigned int default_majority) DECLSPEC_HIDDEN; struct hlsl_type *get_type(struct hlsl_scope *scope, const char *name, BOOL recursive) DECLSPEC_HIDDEN; BOOL find_function(const char *name) DECLSPEC_HIDDEN; unsigned int components_count_type(struct hlsl_type *type) DECLSPEC_HIDDEN; diff --git a/dlls/d3dcompiler_43/hlsl.y b/dlls/d3dcompiler_43/hlsl.y index 5381fa211a..833472a351 100644 --- a/dlls/d3dcompiler_43/hlsl.y +++ b/dlls/d3dcompiler_43/hlsl.y @@ -576,6 +576,9 @@ static struct list *declare_vars(struct hlsl_type *basic_type, DWORD modifiers, BOOL ret, local = TRUE; struct list *statements_list = d3dcompiler_alloc(sizeof(*statements_list)); + if (basic_type->type == HLSL_CLASS_MATRIX) + assert(basic_type->modifiers & HLSL_MODIFIERS_MAJORITY_MASK); + if (!statements_list) { ERR("Out of memory.\n"); @@ -717,14 +720,32 @@ static BOOL add_struct_field(struct list *fields, struct hlsl_struct_field *fiel return TRUE; } -static struct hlsl_type *apply_type_modifiers(struct hlsl_type *type, DWORD *modifiers, struct source_location loc) +static struct hlsl_type *apply_type_modifiers(struct hlsl_type *type, + unsigned int *modifiers, struct source_location loc) { + unsigned int default_majority = 0; struct hlsl_type *new_type; - if (!(*modifiers & HLSL_TYPE_MODIFIERS_MASK)) + /* This function is only used for declarations (i.e. variables and struct + * fields), which should inherit the matrix majority. We only explicitly set + * the default majority for declarations—typedefs depend on this—but we + * want to always set it, so that an hlsl_type object is never used to + * represent two different majorities (and thus can be used to store its + * register size, etc.) */ + if (!(*modifiers & HLSL_MODIFIERS_MAJORITY_MASK) + && !(type->modifiers & HLSL_MODIFIERS_MAJORITY_MASK) + && type->type == HLSL_CLASS_MATRIX) + { + if (hlsl_ctx.matrix_majority == HLSL_COLUMN_MAJOR) + default_majority = HLSL_MODIFIER_COLUMN_MAJOR; + else + default_majority = HLSL_MODIFIER_ROW_MAJOR; + } + + if (!default_majority && !(*modifiers & HLSL_TYPE_MODIFIERS_MASK)) return type; - if (!(new_type = clone_hlsl_type(type))) + if (!(new_type = clone_hlsl_type(type, default_majority))) return NULL; new_type->modifiers = add_modifiers(new_type->modifiers, *modifiers, loc); @@ -738,6 +759,9 @@ static struct list *gen_struct_fields(struct hlsl_type *type, DWORD modifiers, s struct hlsl_struct_field *field; struct list *list; + if (type->type == HLSL_CLASS_MATRIX) + assert(type->modifiers & HLSL_MODIFIERS_MAJORITY_MASK); + list = d3dcompiler_alloc(sizeof(*list)); if (!list) { @@ -801,7 +825,7 @@ static BOOL add_typedef(DWORD modifiers, struct hlsl_type *orig_type, struct lis if (v->array_size) type = new_array_type(orig_type, v->array_size); else - type = clone_hlsl_type(orig_type); + type = clone_hlsl_type(orig_type, 0); if (!type) { ERR("Out of memory\n"); @@ -834,6 +858,9 @@ static BOOL add_func_parameter(struct list *list, struct parse_parameter *param, { struct hlsl_ir_var *decl = d3dcompiler_alloc(sizeof(*decl)); + if (param->type->type == HLSL_CLASS_MATRIX) + assert(param->type->modifiers & HLSL_MODIFIERS_MAJORITY_MASK); + if (!decl) { ERR("Out of memory.\n"); @@ -2066,7 +2093,7 @@ postfix_expr: primary_expr } inc = new_unary_expr(HLSL_IR_UNOP_POSTINC, node_from_list($1), loc); /* Post increment/decrement expressions are considered const */ - inc->data_type = clone_hlsl_type(inc->data_type); + inc->data_type = clone_hlsl_type(inc->data_type, 0); inc->data_type->modifiers |= HLSL_MODIFIER_CONST; $$ = append_unop($1, inc); } @@ -2083,7 +2110,7 @@ postfix_expr: primary_expr } inc = new_unary_expr(HLSL_IR_UNOP_POSTDEC, node_from_list($1), loc); /* Post increment/decrement expressions are considered const */ - inc->data_type = clone_hlsl_type(inc->data_type); + inc->data_type = clone_hlsl_type(inc->data_type, 0); inc->data_type->modifiers |= HLSL_MODIFIER_CONST; $$ = append_unop($1, inc); } diff --git a/dlls/d3dcompiler_43/utils.c b/dlls/d3dcompiler_43/utils.c index 84323c334f..ff779891fd 100644 --- a/dlls/d3dcompiler_43/utils.c +++ b/dlls/d3dcompiler_43/utils.c @@ -927,7 +927,7 @@ BOOL compare_hlsl_types(const struct hlsl_type *t1, const struct hlsl_type *t2) return TRUE; } -struct hlsl_type *clone_hlsl_type(struct hlsl_type *old) +struct hlsl_type *clone_hlsl_type(struct hlsl_type *old, unsigned int default_majority) { struct hlsl_type *type; struct hlsl_struct_field *old_field, *field; @@ -952,11 +952,13 @@ struct hlsl_type *clone_hlsl_type(struct hlsl_type *old) type->dimx = old->dimx; type->dimy = old->dimy; type->modifiers = old->modifiers; + if (!(type->modifiers & HLSL_MODIFIERS_MAJORITY_MASK)) + type->modifiers |= default_majority; type->sampler_dim = old->sampler_dim; switch (old->type) { case HLSL_CLASS_ARRAY: - type->e.array.type = old->e.array.type; + type->e.array.type = clone_hlsl_type(old->e.array.type, default_majority); type->e.array.elements_count = old->e.array.elements_count; break; case HLSL_CLASS_STRUCT: @@ -984,7 +986,7 @@ struct hlsl_type *clone_hlsl_type(struct hlsl_type *old) d3dcompiler_free(type); return NULL; } - field->type = clone_hlsl_type(old_field->type); + field->type = clone_hlsl_type(old_field->type, default_majority); field->name = d3dcompiler_strdup(old_field->name); if (old_field->semantic) field->semantic = d3dcompiler_strdup(old_field->semantic);
1
0
0
0
Zebediah Figura : d3dcompiler: Check for multiple matrix majority keywords on typedefs.
by Alexandre Julliard
14 Apr '20
14 Apr '20
Module: wine Branch: master Commit: d05ee3674efc9227ab628ac71d8acc6e82aa2560 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=d05ee3674efc9227ab628ac7…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Thu Apr 2 16:14:10 2020 -0500 d3dcompiler: Check for multiple matrix majority keywords on typedefs. Signed-off-by: Zebediah Figura <zfigura(a)codeweavers.com> Signed-off-by: Matteo Bruni <mbruni(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/d3dcompiler_43/hlsl.y | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/dlls/d3dcompiler_43/hlsl.y b/dlls/d3dcompiler_43/hlsl.y index 67393f6ca9..5381fa211a 100644 --- a/dlls/d3dcompiler_43/hlsl.y +++ b/dlls/d3dcompiler_43/hlsl.y @@ -814,6 +814,10 @@ static BOOL add_typedef(DWORD modifiers, struct hlsl_type *orig_type, struct lis if (type->type != HLSL_CLASS_MATRIX) check_invalid_matrix_modifiers(type->modifiers, v->loc); + if ((type->modifiers & HLSL_MODIFIER_COLUMN_MAJOR) + && (type->modifiers & HLSL_MODIFIER_ROW_MAJOR)) + hlsl_report_message(v->loc, HLSL_LEVEL_ERROR, "more than one matrix majority keyword"); + ret = add_type_to_scope(hlsl_ctx.cur_scope, type); if (!ret) {
1
0
0
0
Damjan Jovanovic : mshtml/tests: Fix a HRESULT comparison in ProtocolSink_ReportResult().
by Alexandre Julliard
13 Apr '20
13 Apr '20
Module: wine Branch: master Commit: 5e75310837e5ec77ebc361d689ea3279fa49ebac URL:
https://source.winehq.org/git/wine.git/?a=commit;h=5e75310837e5ec77ebc361d6…
Author: Damjan Jovanovic <damjan.jov(a)gmail.com> Date: Fri Apr 10 13:30:22 2020 +0200 mshtml/tests: Fix a HRESULT comparison in ProtocolSink_ReportResult(). ProtocolSink_ReportResult() only checks expect_hrResult is non-zero, instead of comparing it against hres like the same code snippet in test_protocol_fail(). Signed-off-by: Damjan Jovanovic <damjan.jov(a)gmail.com> Signed-off-by: Jacek Caban <jacek(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/mshtml/tests/protocol.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/mshtml/tests/protocol.c b/dlls/mshtml/tests/protocol.c index 8f37d09c55..ba767d21c6 100644 --- a/dlls/mshtml/tests/protocol.c +++ b/dlls/mshtml/tests/protocol.c @@ -139,7 +139,7 @@ static HRESULT WINAPI ProtocolSink_ReportResult(IInternetProtocolSink *iface, HR CHECK_EXPECT(ReportResult); if(expect_hr_win32err) { - ok((hrResult&0xffff0000) == ((FACILITY_WIN32 << 16)|0x80000000) || expect_hrResult, + ok((hrResult&0xffff0000) == ((FACILITY_WIN32 << 16)|0x80000000) || hrResult == expect_hrResult, "expected win32 err or %08x got: %08x\n", expect_hrResult, hrResult); }else { ok(hrResult == expect_hrResult || (expect_hrResult == E_INVALIDARG && hrResult == MK_E_SYNTAX)
1
0
0
0
Nikolay Sivov : mf: Forward MEEndOfPresentation event from Media Session.
by Alexandre Julliard
13 Apr '20
13 Apr '20
Module: wine Branch: master Commit: 8262ea2909e1b95610f81e38dc68910beaa321b9 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=8262ea2909e1b95610f81e38…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Mon Apr 13 19:05:58 2020 +0300 mf: Forward MEEndOfPresentation event from Media Session. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/mf/session.c | 121 ++++++++++++++++++++++++++++++++++++++++++++++++++---- 1 file changed, 113 insertions(+), 8 deletions(-) diff --git a/dlls/mf/session.c b/dlls/mf/session.c index 85bf4e9cba..3474b242a4 100644 --- a/dlls/mf/session.c +++ b/dlls/mf/session.c @@ -98,12 +98,18 @@ enum object_state OBJ_STATE_INVALID, }; +enum media_source_flags +{ + SOURCE_FLAG_END_OF_PRESENTATION = 0x1, +}; + struct media_source { struct list entry; IMFMediaSource *source; IMFPresentationDescriptor *pd; enum object_state state; + unsigned int flags; }; struct media_sink @@ -178,6 +184,7 @@ enum presentation_flags SESSION_FLAG_PRESENTATION_CLOCK_SET = 0x2, SESSION_FLAG_FINALIZE_SINKS = 0x4, SESSION_FLAG_NEEDS_PREROLL = 0x8, + SESSION_FLAG_END_OF_PRESENTATION = 0x10, }; struct media_session @@ -2055,20 +2062,30 @@ static HRESULT session_start_clock(struct media_session *session) return hr; } +static struct topo_node *session_get_node_object(struct media_session *session, IUnknown *object, + MF_TOPOLOGY_TYPE node_type) +{ + struct topo_node *node = NULL; + + LIST_FOR_EACH_ENTRY(node, &session->presentation.nodes, struct topo_node, entry) + { + if (node->type == node_type && object == node->object.object) + break; + } + + return node; +} + static BOOL session_set_node_object_state(struct media_session *session, IUnknown *object, MF_TOPOLOGY_TYPE node_type, enum object_state state) { struct topo_node *node; BOOL changed = FALSE; - LIST_FOR_EACH_ENTRY(node, &session->presentation.nodes, struct topo_node, entry) + if ((node = session_get_node_object(session, object, node_type))) { - if (node->type == node_type && object == node->object.object) - { - changed = node->state != state; - node->state = state; - break; - } + changed = node->state != state; + node->state = state; } return changed; @@ -2680,6 +2697,80 @@ static void session_sink_invalidated(struct media_session *session, IMFMediaEven session_set_topo_status(session, S_OK, MF_TOPOSTATUS_ENDED); } +static BOOL session_nodes_is_mask_set(struct media_session *session, MF_TOPOLOGY_TYPE node_type, unsigned int flags) +{ + struct media_source *source; + struct topo_node *node; + + if (node_type == MF_TOPOLOGY_MAX) + { + LIST_FOR_EACH_ENTRY(source, &session->presentation.sources, struct media_source, entry) + { + if ((source->flags & flags) != flags) + return FALSE; + } + } + else + { + LIST_FOR_EACH_ENTRY(node, &session->presentation.nodes, struct topo_node, entry) + { + if (node->type == node_type && (node->flags & flags) != flags) + return FALSE; + } + } + + return TRUE; +} + +static void session_raise_end_of_presentation(struct media_session *session) +{ + if (!(session_nodes_is_mask_set(session, MF_TOPOLOGY_SOURCESTREAM_NODE, TOPO_NODE_END_OF_STREAM))) + return; + + if (!(session->presentation.flags & SESSION_FLAG_END_OF_PRESENTATION)) + { + if (session_nodes_is_mask_set(session, MF_TOPOLOGY_MAX, SOURCE_FLAG_END_OF_PRESENTATION)) + { + IMFMediaEventQueue_QueueEventParamVar(session->event_queue, MEEndOfPresentation, &GUID_NULL, S_OK, NULL); + session->presentation.flags |= SESSION_FLAG_END_OF_PRESENTATION; + } + } +} + +static void session_handle_end_of_stream(struct media_session *session, IMFMediaStream *stream) +{ + struct topo_node *node; + + if (!(node = session_get_node_object(session, (IUnknown *)stream, MF_TOPOLOGY_SOURCESTREAM_NODE)) + || node->flags & TOPO_NODE_END_OF_STREAM) + { + return; + } + + session_deliver_sample(session, stream, NULL); + + session_raise_end_of_presentation(session); +} + +static void session_handle_end_of_presentation(struct media_session *session, IMFMediaSource *object) +{ + struct media_source *source; + + LIST_FOR_EACH_ENTRY(source, &session->presentation.sources, struct media_source, entry) + { + if (source->source == object) + { + if (!(source->flags & SOURCE_FLAG_END_OF_PRESENTATION)) + { + source->flags |= SOURCE_FLAG_END_OF_PRESENTATION; + session_raise_end_of_presentation(session); + } + + break; + } + } +} + static HRESULT WINAPI session_events_callback_Invoke(IMFAsyncCallback *iface, IMFAsyncResult *result) { struct media_session *session = impl_from_events_callback_IMFAsyncCallback(iface); @@ -2765,10 +2856,24 @@ static HRESULT WINAPI session_events_callback_Invoke(IMFAsyncCallback *iface, IM break; case MEMediaSample: + + EnterCriticalSection(&session->cs); + session_deliver_sample(session, (IMFMediaStream *)event_source, &value); + LeaveCriticalSection(&session->cs); + + break; case MEEndOfStream: EnterCriticalSection(&session->cs); - session_deliver_sample(session, (IMFMediaStream *)event_source, event_type == MEMediaSample ? &value : NULL); + session_handle_end_of_stream(session, (IMFMediaStream *)event_source); + LeaveCriticalSection(&session->cs); + + break; + + case MEEndOfPresentation: + + EnterCriticalSection(&session->cs); + session_handle_end_of_presentation(session, (IMFMediaSource *)event_source); LeaveCriticalSection(&session->cs); break;
1
0
0
0
Nikolay Sivov : mf: Handle EndOfStream events within Media Session.
by Alexandre Julliard
13 Apr '20
13 Apr '20
Module: wine Branch: master Commit: df0608ac831f1793491754e7ca9dadc275711154 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=df0608ac831f1793491754e7…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Mon Apr 13 19:05:57 2020 +0300 mf: Handle EndOfStream events within Media Session. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/mf/session.c | 260 +++++++++++++++++++++++++++++++++--------------------- 1 file changed, 157 insertions(+), 103 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=df0608ac831f17934917…
1
0
0
0
Nikolay Sivov : mf/tests: Add some tests for node list management.
by Alexandre Julliard
13 Apr '20
13 Apr '20
Module: wine Branch: master Commit: a34279daeecf054e6863ab4cb5eed70010e76904 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=a34279daeecf054e6863ab4c…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Mon Apr 13 19:05:56 2020 +0300 mf/tests: Add some tests for node list management. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/mf/tests/mf.c | 62 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) diff --git a/dlls/mf/tests/mf.c b/dlls/mf/tests/mf.c index 6c44e4728e..dd6c935b8c 100644 --- a/dlls/mf/tests/mf.c +++ b/dlls/mf/tests/mf.c @@ -735,6 +735,68 @@ static void test_topology(void) IMFTopologyNode_Release(node2); IMFTopologyNode_Release(node); + /* Add one node, connect to another that hasn't been added. */ + hr = IMFTopology_Clear(topology); + ok(hr == S_OK, "Failed to clear topology, hr %#x.\n", hr); + + hr = MFCreateTopologyNode(MF_TOPOLOGY_SOURCESTREAM_NODE, &node); + ok(hr == S_OK, "Failed to create topology node, hr %#x.\n", hr); + + hr = MFCreateTopologyNode(MF_TOPOLOGY_OUTPUT_NODE, &node2); + ok(hr == S_OK, "Failed to create topology node, hr %#x.\n", hr); + + hr = IMFTopology_AddNode(topology, node); + ok(hr == S_OK, "Failed to add a node, hr %#x.\n", hr); + + hr = IMFTopology_GetNodeCount(topology, &node_count); + ok(hr == S_OK, "Failed to get node count, hr %#x.\n", hr); + ok(node_count == 1, "Unexpected node count.\n"); + + hr = IMFTopologyNode_ConnectOutput(node, 0, node2, 0); + ok(hr == S_OK, "Failed to connect nodes, hr %#x.\n", hr); + + hr = IMFTopology_GetNodeCount(topology, &node_count); + ok(hr == S_OK, "Failed to get node count, hr %#x.\n", hr); + ok(node_count == 1, "Unexpected node count.\n"); + + IMFTopologyNode_Release(node); + IMFTopologyNode_Release(node2); + + /* Add same node to different topologies. */ + hr = IMFTopology_Clear(topology); + ok(hr == S_OK, "Failed to clear topology, hr %#x.\n", hr); + + hr = MFCreateTopology(&topology2); + ok(hr == S_OK, "Failed to create topology, hr %#x.\n", hr); + + hr = MFCreateTopologyNode(MF_TOPOLOGY_SOURCESTREAM_NODE, &node); + ok(hr == S_OK, "Failed to create topology node, hr %#x.\n", hr); + + hr = IMFTopology_AddNode(topology, node); + ok(hr == S_OK, "Failed to add a node, hr %#x.\n", hr); + EXPECT_REF(node, 2); + + hr = IMFTopology_GetNodeCount(topology, &node_count); + ok(hr == S_OK, "Failed to get node count, hr %#x.\n", hr); + ok(node_count == 1, "Unexpected node count.\n"); + + hr = IMFTopology_GetNodeCount(topology2, &node_count); + ok(hr == S_OK, "Failed to get node count, hr %#x.\n", hr); + ok(node_count == 0, "Unexpected node count.\n"); + + hr = IMFTopology_AddNode(topology2, node); + ok(hr == S_OK, "Failed to add a node, hr %#x.\n", hr); + EXPECT_REF(node, 3); + + hr = IMFTopology_GetNodeCount(topology, &node_count); + ok(hr == S_OK, "Failed to get node count, hr %#x.\n", hr); + ok(node_count == 1, "Unexpected node count.\n"); + + hr = IMFTopology_GetNodeCount(topology2, &node_count); + ok(hr == S_OK, "Failed to get node count, hr %#x.\n", hr); + ok(node_count == 1, "Unexpected node count.\n"); + + IMFTopology_Release(topology2); IMFTopology_Release(topology); }
1
0
0
0
Nikolay Sivov : mf: Implement sink prerolling.
by Alexandre Julliard
13 Apr '20
13 Apr '20
Module: wine Branch: master Commit: 8a299c4bc33fdb26d31e7ab13baa80fa0ecb3add URL:
https://source.winehq.org/git/wine.git/?a=commit;h=8a299c4bc33fdb26d31e7ab1…
Author: Nikolay Sivov <nsivov(a)codeweavers.com> Date: Mon Apr 13 19:05:55 2020 +0300 mf: Implement sink prerolling. Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/mf/session.c | 118 ++++++++++++++++++++++++++++++++++++++++++------------ 1 file changed, 93 insertions(+), 25 deletions(-) diff --git a/dlls/mf/session.c b/dlls/mf/session.c index 5b9f720815..bc4cac6ef0 100644 --- a/dlls/mf/session.c +++ b/dlls/mf/session.c @@ -76,6 +76,7 @@ enum session_state { SESSION_STATE_STOPPED = 0, SESSION_STATE_STARTING_SOURCES, + SESSION_STATE_PREROLLING_SINKS, SESSION_STATE_STARTING_SINKS, SESSION_STATE_STARTED, SESSION_STATE_PAUSING_SINKS, @@ -93,6 +94,7 @@ enum object_state OBJ_STATE_STOPPED = 0, OBJ_STATE_STARTED, OBJ_STATE_PAUSED, + OBJ_STATE_PREROLLED, OBJ_STATE_INVALID, }; @@ -108,6 +110,7 @@ struct media_sink { struct list entry; IMFMediaSink *sink; + IMFMediaSinkPreroll *preroll; IMFMediaEventGenerator *event_generator; BOOL finalized; }; @@ -168,6 +171,7 @@ enum presentation_flags SESSION_FLAG_SOURCES_SUBSCRIBED = 0x1, SESSION_FLAG_PRESENTATION_CLOCK_SET = 0x2, SESSION_FLAG_FINALIZE_SINKS = 0x4, + SESSION_FLAG_NEEDS_PREROLL = 0x8, }; struct media_session @@ -722,6 +726,8 @@ static void session_clear_presentation(struct media_session *session) if (sink->sink) IMFMediaSink_Release(sink->sink); + if (sink->preroll) + IMFMediaSinkPreroll_Release(sink->preroll); if (sink->event_generator) IMFMediaEventGenerator_Release(sink->event_generator); heap_free(sink); @@ -982,6 +988,7 @@ static DWORD session_get_object_rate_caps(IUnknown *object) static HRESULT session_add_media_sink(struct media_session *session, IMFTopologyNode *node, IMFMediaSink *sink) { struct media_sink *media_sink; + DWORD flags; LIST_FOR_EACH_ENTRY(media_sink, &session->presentation.sinks, struct media_sink, entry) { @@ -997,6 +1004,12 @@ static HRESULT session_add_media_sink(struct media_session *session, IMFTopology IMFMediaSink_QueryInterface(media_sink->sink, &IID_IMFMediaEventGenerator, (void **)&media_sink->event_generator); + if (SUCCEEDED(IMFMediaSink_GetCharacteristics(sink, &flags)) && flags & MEDIASINK_CAN_PREROLL) + { + if (SUCCEEDED(IMFMediaSink_QueryInterface(media_sink->sink, &IID_IMFMediaSinkPreroll, (void **)&media_sink->preroll))) + session->presentation.flags |= SESSION_FLAG_NEEDS_PREROLL; + } + list_add_tail(&session->presentation.sinks, &media_sink->entry); return S_OK; @@ -1915,6 +1928,8 @@ static enum object_state session_get_object_state_for_event(MediaEventType event case MEStreamStopped: case MEStreamSinkStopped: return OBJ_STATE_STOPPED; + case MEStreamSinkPrerolled: + return OBJ_STATE_PREROLLED; default: return OBJ_STATE_INVALID; } @@ -1931,11 +1946,10 @@ static void session_set_consumed_clock(IUnknown *object, IMFPresentationClock *c } } -static HRESULT session_start_clock(struct media_session *session) +static void session_set_presentation_clock(struct media_session *session) { IMFPresentationTimeSource *time_source = NULL; struct media_source *source; - LONGLONG start_offset = 0; struct media_sink *sink; struct topo_node *node; HRESULT hr; @@ -2007,6 +2021,12 @@ static HRESULT session_start_clock(struct media_session *session) session->presentation.flags |= SESSION_FLAG_PRESENTATION_CLOCK_SET; } +} + +static HRESULT session_start_clock(struct media_session *session) +{ + LONGLONG start_offset = 0; + HRESULT hr; if (IsEqualGUID(&session->presentation.time_format, &GUID_NULL)) { @@ -2026,14 +2046,36 @@ static HRESULT session_start_clock(struct media_session *session) return hr; } +static BOOL session_set_node_object_state(struct media_session *session, IUnknown *object, + MF_TOPOLOGY_TYPE node_type, enum object_state state) +{ + struct topo_node *node; + BOOL changed = FALSE; + + LIST_FOR_EACH_ENTRY(node, &session->presentation.nodes, struct topo_node, entry) + { + if (node->type == node_type && object == node->object.object) + { + changed = node->state != state; + node->state = state; + break; + } + } + + return changed; +} static void session_set_source_object_state(struct media_session *session, IUnknown *object, MediaEventType event_type) { + IMFStreamSink *stream_sink; struct media_source *src; + struct media_sink *sink; enum object_state state; struct topo_node *node; + unsigned int i, count; BOOL changed = FALSE; + HRESULT hr; if ((state = session_get_object_state_for_event(event_type)) == OBJ_STATE_INVALID) return; @@ -2058,15 +2100,7 @@ static void session_set_source_object_state(struct media_session *session, IUnkn case MEStreamPaused: case MEStreamStopped: - LIST_FOR_EACH_ENTRY(node, &session->presentation.nodes, struct topo_node, entry) - { - if (node->type == MF_TOPOLOGY_SOURCESTREAM_NODE && object == node->object.object) - { - changed = node->state != state; - node->state = state; - break; - } - } + changed = session_set_node_object_state(session, object, MF_TOPOLOGY_SOURCESTREAM_NODE, state); default: ; } @@ -2081,7 +2115,44 @@ static void session_set_source_object_state(struct media_session *session, IUnkn break; session_set_topo_status(session, S_OK, MF_TOPOSTATUS_STARTED_SOURCE); - if (SUCCEEDED(session_start_clock(session))) + + session_set_presentation_clock(session); + + if (session->presentation.flags & SESSION_FLAG_NEEDS_PREROLL) + { + MFTIME preroll_time = 0; + + if (session->presentation.start_position.vt == VT_I8) + preroll_time = session->presentation.start_position.hVal.QuadPart; + + /* Mark stream sinks without prerolling support as PREROLLED to keep state test logic generic. */ + LIST_FOR_EACH_ENTRY(sink, &session->presentation.sinks, struct media_sink, entry) + { + if (sink->preroll) + { + /* FIXME: abort and enter error state on failure. */ + if (FAILED(hr = IMFMediaSinkPreroll_NotifyPreroll(sink->preroll, preroll_time))) + WARN("Preroll notification failed, hr %#x.\n", hr); + } + else + { + if (SUCCEEDED(IMFMediaSink_GetStreamSinkCount(sink->sink, &count))) + { + for (i = 0; i < count; ++i) + { + if (SUCCEEDED(IMFMediaSink_GetStreamSinkByIndex(sink->sink, i, &stream_sink))) + { + session_set_node_object_state(session, (IUnknown *)stream_sink, MF_TOPOLOGY_OUTPUT_NODE, + OBJ_STATE_PREROLLED); + IMFStreamSink_Release(stream_sink); + } + } + } + } + } + session->state = SESSION_STATE_PREROLLING_SINKS; + } + else if (SUCCEEDED(session_start_clock(session))) session->state = SESSION_STATE_STARTING_SINKS; break; @@ -2137,31 +2208,27 @@ static void session_set_sink_stream_state(struct media_session *session, IMFStre MediaEventType event_type) { struct media_source *source; - struct topo_node *node; enum object_state state; - BOOL changed = FALSE; IMFMediaEvent *event; DWORD caps, flags; + BOOL changed; HRESULT hr; if ((state = session_get_object_state_for_event(event_type)) == OBJ_STATE_INVALID) return; - LIST_FOR_EACH_ENTRY(node, &session->presentation.nodes, struct topo_node, entry) - { - if (node->type == MF_TOPOLOGY_OUTPUT_NODE && stream == node->object.sink_stream) - { - changed = node->state != state; - node->state = state; - break; - } - } - - if (!changed) + if (!(changed = session_set_node_object_state(session, (IUnknown *)stream, MF_TOPOLOGY_OUTPUT_NODE, state))) return; switch (session->state) { + case SESSION_STATE_PREROLLING_SINKS: + if (!session_is_output_nodes_state(session, OBJ_STATE_PREROLLED)) + break; + + if (SUCCEEDED(session_start_clock(session))) + session->state = SESSION_STATE_STARTING_SINKS; + break; case SESSION_STATE_STARTING_SINKS: if (!session_is_output_nodes_state(session, OBJ_STATE_STARTED)) break; @@ -2630,6 +2697,7 @@ static HRESULT WINAPI session_events_callback_Invoke(IMFAsyncCallback *iface, IM case MEStreamSinkStarted: case MEStreamSinkPaused: case MEStreamSinkStopped: + case MEStreamSinkPrerolled: EnterCriticalSection(&session->cs); session_set_sink_stream_state(session, (IMFStreamSink *)event_source, event_type);
1
0
0
0
Serge Gautherie : winapi_test: Add DYNAMIC_TIME_ZONE_INFORMATION to tests.dat.
by Alexandre Julliard
13 Apr '20
13 Apr '20
Module: wine Branch: master Commit: 930ff8786fd52287732c0286dd050004ac7c003d URL:
https://source.winehq.org/git/wine.git/?a=commit;h=930ff8786fd52287732c0286…
Author: Serge Gautherie <winehq-git_serge_180711(a)gautherie.fr> Date: Sun Apr 12 19:13:43 2020 +0200 winapi_test: Add DYNAMIC_TIME_ZONE_INFORMATION to tests.dat. Signed-off-by: Serge Gautherie <winehq-git_serge_180711(a)gautherie.fr> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/kernel32/tests/generated.c | 88 +++++++++++++++++++++++++++++++++++++++++ tools/winapi/tests.dat | 2 + 2 files changed, 90 insertions(+) diff --git a/dlls/kernel32/tests/generated.c b/dlls/kernel32/tests/generated.c index 09ce14698a..7606580fa4 100644 --- a/dlls/kernel32/tests/generated.c +++ b/dlls/kernel32/tests/generated.c @@ -1882,6 +1882,40 @@ static void test_pack_WIN32_STREAM_ID(void) TEST_FIELD_OFFSET(WIN32_STREAM_ID, cStreamName, 20) } +static void test_pack_DYNAMIC_TIME_ZONE_INFORMATION(void) +{ + /* DYNAMIC_TIME_ZONE_INFORMATION */ + TEST_TYPE_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, 432) + TEST_TYPE_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, 4) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, Bias, 4) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, Bias, 4) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, Bias, 0) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, StandardName, 64) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, StandardName, 2) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, StandardName, 4) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, StandardDate, 16) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, StandardDate, 2) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, StandardDate, 68) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, StandardBias, 4) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, StandardBias, 4) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, StandardBias, 84) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, DaylightName, 64) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, DaylightName, 2) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, DaylightName, 88) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, DaylightDate, 16) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, DaylightDate, 2) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, DaylightDate, 152) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, DaylightBias, 4) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, DaylightBias, 4) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, DaylightBias, 168) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, TimeZoneKeyName, 256) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, TimeZoneKeyName, 2) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, TimeZoneKeyName, 172) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, DynamicDaylightTimeDisabled, 1) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, DynamicDaylightTimeDisabled, 1) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, DynamicDaylightTimeDisabled, 428) +} + static void test_pack_LPTIME_ZONE_INFORMATION(void) { /* LPTIME_ZONE_INFORMATION */ @@ -1891,6 +1925,15 @@ static void test_pack_LPTIME_ZONE_INFORMATION(void) TEST_TARGET_ALIGN(LPTIME_ZONE_INFORMATION, 4) } +static void test_pack_PDYNAMIC_TIME_ZONE_INFORMATION(void) +{ + /* PDYNAMIC_TIME_ZONE_INFORMATION */ + TEST_TYPE_SIZE (PDYNAMIC_TIME_ZONE_INFORMATION, 8) + TEST_TYPE_ALIGN (PDYNAMIC_TIME_ZONE_INFORMATION, 8) + TEST_TARGET_SIZE (PDYNAMIC_TIME_ZONE_INFORMATION, 432) + TEST_TARGET_ALIGN(PDYNAMIC_TIME_ZONE_INFORMATION, 4) +} + static void test_pack_PTIME_ZONE_INFORMATION(void) { /* PTIME_ZONE_INFORMATION */ @@ -3739,6 +3782,40 @@ static void test_pack_WIN32_STREAM_ID(void) TEST_FIELD_OFFSET(WIN32_STREAM_ID, cStreamName, 20) } +static void test_pack_DYNAMIC_TIME_ZONE_INFORMATION(void) +{ + /* DYNAMIC_TIME_ZONE_INFORMATION */ + TEST_TYPE_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, 432) + TEST_TYPE_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, 4) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, Bias, 4) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, Bias, 4) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, Bias, 0) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, StandardName, 64) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, StandardName, 2) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, StandardName, 4) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, StandardDate, 16) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, StandardDate, 2) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, StandardDate, 68) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, StandardBias, 4) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, StandardBias, 4) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, StandardBias, 84) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, DaylightName, 64) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, DaylightName, 2) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, DaylightName, 88) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, DaylightDate, 16) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, DaylightDate, 2) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, DaylightDate, 152) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, DaylightBias, 4) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, DaylightBias, 4) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, DaylightBias, 168) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, TimeZoneKeyName, 256) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, TimeZoneKeyName, 2) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, TimeZoneKeyName, 172) + TEST_FIELD_SIZE (DYNAMIC_TIME_ZONE_INFORMATION, DynamicDaylightTimeDisabled, 1) + TEST_FIELD_ALIGN (DYNAMIC_TIME_ZONE_INFORMATION, DynamicDaylightTimeDisabled, 1) + TEST_FIELD_OFFSET(DYNAMIC_TIME_ZONE_INFORMATION, DynamicDaylightTimeDisabled, 428) +} + static void test_pack_LPTIME_ZONE_INFORMATION(void) { /* LPTIME_ZONE_INFORMATION */ @@ -3748,6 +3825,15 @@ static void test_pack_LPTIME_ZONE_INFORMATION(void) TEST_TARGET_ALIGN(LPTIME_ZONE_INFORMATION, 4) } +static void test_pack_PDYNAMIC_TIME_ZONE_INFORMATION(void) +{ + /* PDYNAMIC_TIME_ZONE_INFORMATION */ + TEST_TYPE_SIZE (PDYNAMIC_TIME_ZONE_INFORMATION, 4) + TEST_TYPE_ALIGN (PDYNAMIC_TIME_ZONE_INFORMATION, 4) + TEST_TARGET_SIZE (PDYNAMIC_TIME_ZONE_INFORMATION, 432) + TEST_TARGET_ALIGN(PDYNAMIC_TIME_ZONE_INFORMATION, 4) +} + static void test_pack_PTIME_ZONE_INFORMATION(void) { /* PTIME_ZONE_INFORMATION */ @@ -3806,6 +3892,7 @@ static void test_pack(void) test_pack_CRITICAL_SECTION_DEBUG(); test_pack_DCB(); test_pack_DEBUG_EVENT(); + test_pack_DYNAMIC_TIME_ZONE_INFORMATION(); test_pack_ENUMRESLANGPROCA(); test_pack_ENUMRESLANGPROCW(); test_pack_ENUMRESNAMEPROCA(); @@ -3881,6 +3968,7 @@ static void test_pack(void) test_pack_PCACTCTX_SECTION_KEYED_DATA_ASSEMBLY_METADATA(); test_pack_PCRITICAL_SECTION(); test_pack_PCRITICAL_SECTION_DEBUG(); + test_pack_PDYNAMIC_TIME_ZONE_INFORMATION(); test_pack_PFIBER_START_ROUTINE(); test_pack_PHKEY(); test_pack_POFSTRUCT(); diff --git a/tools/winapi/tests.dat b/tools/winapi/tests.dat index 254711bc75..3f470d48e7 100644 --- a/tools/winapi/tests.dat +++ b/tools/winapi/tests.dat @@ -497,6 +497,7 @@ CRITICAL_SECTION CRITICAL_SECTION_DEBUG DCB DEBUG_EVENT +DYNAMIC_TIME_ZONE_INFORMATION ENUMRESLANGPROCA ENUMRESLANGPROCW ENUMRESNAMEPROCA @@ -578,6 +579,7 @@ PCACTCTX_SECTION_KEYED_DATA_2600 PCACTCTX_SECTION_KEYED_DATA_ASSEMBLY_METADATA PCRITICAL_SECTION PCRITICAL_SECTION_DEBUG +PDYNAMIC_TIME_ZONE_INFORMATION PFIBER_START_ROUTINE !PFILETIME # FIXME: 20040821: Mishandled by winapi_test PHKEY
1
0
0
0
← Newer
1
...
62
63
64
65
66
67
68
...
102
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
Results per page:
10
25
50
100
200