// File: /workspace/github_c_makefile_star2_O2/dxwc[P]sfeed/sfeed.c
// Function: xmltagstart
static void
xmltagstart(XMLParser *p, const char *t, size_t tl)
{
	enum TagId tagid;

	if (ISINCONTENT(ctx)) {
		ctx.attrcount = 0;
		if (ctx.contenttype == ContentTypeHTML) {
			xmldata(p, "<", 1);
			xmldata(p, t, tl);
		}
		return;
	}

	/* start of RSS or Atom item / entry */
	if (ctx.feedtype == FeedTypeNone) {
		if (istag(t, tl, STRP("entry")))
			ctx.feedtype = FeedTypeAtom;
		else if (istag(t, tl, STRP("item")))
			ctx.feedtype = FeedTypeRSS;
		return;
	}

	/* field tagid already set, nested tags are not allowed: return */
	if (ctx.tagid)
		return;

	/* in item */
	tagid = gettag(ctx.feedtype, t, tl);
	ctx.tagid = tagid;

	/* without a rel attribute the default link type is "alternate" */
	if (tagid == AtomTagLink) {
		atomlinktype = AtomTagLinkAlternate;
		string_clear(&atomlink); /* reuse and clear temporary link */
	} else if (tagid == RSSTagGuid) {
		/* without a ispermalink attribute the default value is "true" */
		rssidpermalink = 1;
	}

	/* map tag type to field: unknown or lesser priority is ignored,
	   when tags of the same type are repeated only the first is used. */
	if (fieldmap[tagid] == -1 || tagid <= ctx.fields[fieldmap[tagid]].tagid) {
		ctx.field = NULL;
		return;
	}

	if (fieldmap[ctx.tagid] == FeedFieldContent) {
		/* handle default content-type per tag, Atom, RSS, MRSS. */
		switch (tagid) {
		case RSSTagContentEncoded:
		case RSSTagDescription:
			ctx.contenttype = ContentTypeHTML;
			break;
		default:
			ctx.contenttype = ContentTypePlain;
		}
		ctx.iscontenttag = 1;
	} else {
		ctx.iscontenttag = 0;
	}

	ctx.field = &(ctx.fields[fieldmap[ctx.tagid]].str);
	ctx.fields[fieldmap[ctx.tagid]].tagid = tagid;
	/* clear field */
	string_clear(ctx.field);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r14
movq %rsi, %rbx
cmpl $0x0, 0x7b67(%rip)      # 0xac94
je 0x3171
cmpl $0x0, 0x7b62(%rip)      # 0xac98
jne 0x3171
andl $0x0, 0x7b65(%rip)      # 0xaca4
cmpl $0x2, 0x7b56(%rip)      # 0xac9c
jne 0x32b1
movq %rdi, %r15
leaq 0x202a(%rip), %rsi      # 0x5180
pushq $0x1
popq %rdx
callq 0x2727
movq %r15, %rdi
movq %rbx, %rsi
movq %r14, %rdx
popq %rbx
popq %r14
popq %r15
jmp 0x2727
movl 0x7b29(%rip), %edi      # 0xaca0
testl %edi, %edi
je 0x31d6
cmpl $0x0, 0x7b0e(%rip)      # 0xac90
jne 0x32b1
movq %rbx, %rsi
callq 0x33d8
movl %eax, 0x7afa(%rip)      # 0xac90
testl %eax, %eax
je 0x32a9
cmpl $0x7, %eax
je 0x322a
cmpl $0x13, %eax
jne 0x3231
movl $0x14, 0x7af2(%rip)     # 0xacac
movq 0x7aef(%rip), %rax      # 0xacb0
testq %rax, %rax
je 0x31c9
movb $0x0, (%rax)
andq $0x0, 0x7ae7(%rip)      # 0xacb8
jmp 0x32a9
leaq 0x1e98(%rip), %rdx      # 0x5075
pushq $0x5
popq %rcx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x33ba
testl %eax, %eax
je 0x31fe
movl $0x2, 0x7aa7(%rip)      # 0xaca0
jmp 0x32b1
leaq 0x1e76(%rip), %rdx      # 0x507b
pushq $0x4
popq %rcx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x33ba
testl %eax, %eax
je 0x32b1
movl $0x1, 0x7a7b(%rip)      # 0xaca0
jmp 0x32b1
movb $0x1, 0x7a77(%rip)      # 0xaca8
movl %eax, %edi
leaq 0x1f56(%rip), %rcx      # 0x5190
movslq (%rcx,%rdi,4), %rcx
shlq $0x5, %rcx
leaq 0x795f(%rip), %rdx      # 0xaba8
cmpl 0x20(%rcx,%rdx), %eax
jbe 0x32a9
leaq (%rcx,%rdx), %rsi
addq $0x20, %rsi
xorl %r8d, %r8d
movl $0x38070, %r9d          # imm = 0x38070
btq %rdi, %r9
jae 0x3280
movl %eax, %edi
addl $-0x5, %edi
xorl %r8d, %r8d
cmpl $0x2, %edi
adcl $0x1, %r8d
movl %r8d, 0x7a20(%rip)      # 0xac9c
pushq $0x1
popq %r8
movl %r8d, 0x7a11(%rip)      # 0xac98
addq %rdx, %rcx
addq $0x8, %rcx
movq %rcx, 0x7913(%rip)      # 0xaba8
movl %eax, (%rsi)
movq (%rcx), %rax
testq %rax, %rax
je 0x32a2
movb $0x0, (%rax)
andq $0x0, 0x8(%rcx)
jmp 0x32b1
andq $0x0, 0x78f7(%rip)      # 0xaba8
popq %rbx
popq %r14
popq %r15
retq